Logistic Regression Python Library
Project description
py4logistic-regression
Logistic Regression Python Library
Getting Started
This project is simply implementation of logistic regression algorithm in python programming language.
Prerequisites
Numpy
Installing
The easiest way to install py4logistic-regression is using pip
pip install py4logistic-regression
Usage
There is 2 public method of Logistic Regression class. It is learn and predict method, learn method takes 5 argument namely x_train, t_train, alpha, and epoch. It is the training data, it's label, learning rate, and number of iteration respectively. predict method takes 1 argument namely x_test. It is the data to be predicted
from py4logistic_regression.regression import logistic_regression
x_train = [[0,0],[0,1],[1,0],[1,1]]
t_train = [0,0,0,1]
classifier = logistic_regression()
classifier.learn(x_train,t_train,0.1,50)
x_test = [[0.02,0.25],[0.97,0.89]]
y = classifier.predict(x_test)
Project details
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file py4logistic_regression-0.0.4.tar.gz.
File metadata
- Download URL: py4logistic_regression-0.0.4.tar.gz
- Upload date:
- Size: 2.3 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.1.1 pkginfo/1.5.0.1 requests/2.22.0 setuptools/46.1.3 requests-toolbelt/0.9.1 tqdm/4.43.0 CPython/3.7.1
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
14be784d48762a7a721549693b7e1bd2f2b5b2e49599cc92ccbcac7de35848ee
|
|
| MD5 |
3190d5c9ff476c2ad739c4515200bd4a
|
|
| BLAKE2b-256 |
81d1b953102f4b7569e427cf55f2ce86a2cbc62b10468977d8f0f09547e3efcb
|
File details
Details for the file py4logistic_regression-0.0.4-py3-none-any.whl.
File metadata
- Download URL: py4logistic_regression-0.0.4-py3-none-any.whl
- Upload date:
- Size: 2.8 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.1.1 pkginfo/1.5.0.1 requests/2.22.0 setuptools/46.1.3 requests-toolbelt/0.9.1 tqdm/4.43.0 CPython/3.7.1
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
ff9a9fd6b0adf9e725f7bd6e87005f0147f923d0cbba11c3bc629e43e8aa94a3
|
|
| MD5 |
bb8e367a207fd4547f82fcfbf54edc14
|
|
| BLAKE2b-256 |
07e4893145ec4351b3167c151808b31efe977f64c24a993f3f44e7d78f670bf6
|