Skip to main content

A Collection of Machine Learning Algorithms implemented from Scratch

Project description

Py-redranger

redranger is a collection of machine learning models implemented from scratch. This library provides simple and easy-to-use implementations of various machine learning algorithms, including linear regression, multiple regression, logistic regression, k-nearest neighbors (KNN), decision trees,random forests,XGB classifier and SVM.

Installation

You can install redranger using pip:

pip install redranger

Usage

Here an examples of how to use the models provided by redranger:

Linear Regression

from redranger import LinearRegression
import numpy as np

# Example data
X = np.array([[1], [2], [3], [4]])
y = np.array([2, 4, 6, 8])

# Create and train the model
model = LinearRegression(learning_rate=0.01, epochs=1000)
model.fit(X, y)

# Make predictions
predictions = model.predict(X)
print("Predictions:", predictions)

similarly implement all other algorithms

Algorithms

redranger includes the following machine learning algorithms:

Linear Regression - A basic regression model that fits a linear relationship between independent and dependent variables. Multiple Linear Regression - An extension of linear regression that handles multiple input features. Logistic Regression - A classification algorithm based on the sigmoid function for binary classification problems. K-Nearest Neighbors (KNN) - A non-parametric method used for classification and regression based on distance metrics. Decision Tree - A tree-based model that splits data based on feature importance to make decisions. Random Forest - An ensemble method using multiple decision trees to improve prediction accuracy and reduce overfitting. Support Vector Machine (SVM) - A powerful classification algorithm that finds the optimal hyperplane for separating classes. XGBoost - An optimized gradient boosting algorithm that builds trees sequentially to minimize errors

Contributing

Contributions are welcome! Please open an issue or submit a pull request on GitHub.

License

This project is licensed under the MIT License. See the LICENSE file for more details.

Contact

For any questions or feedback, please contact Karthikeyan.

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

redranger-0.1.1.tar.gz (9.5 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

redranger-0.1.1-py3-none-any.whl (12.1 kB view details)

Uploaded Python 3

File details

Details for the file redranger-0.1.1.tar.gz.

File metadata

  • Download URL: redranger-0.1.1.tar.gz
  • Upload date:
  • Size: 9.5 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.13.1

File hashes

Hashes for redranger-0.1.1.tar.gz
Algorithm Hash digest
SHA256 3a5712e5dfc4d9c06dc1152272135163d8a2d9d73b4033f45eb00dcd7eef9f5c
MD5 363b5e94f8c3b0ca43ec49c2ac08be86
BLAKE2b-256 9b800334caeaeaaffe634657aa844500ef9c5046b86af625a776f94c73b4e7ac

See more details on using hashes here.

File details

Details for the file redranger-0.1.1-py3-none-any.whl.

File metadata

  • Download URL: redranger-0.1.1-py3-none-any.whl
  • Upload date:
  • Size: 12.1 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.13.1

File hashes

Hashes for redranger-0.1.1-py3-none-any.whl
Algorithm Hash digest
SHA256 5b467abe7184bf5edd4ebad2ebe82b5150125a0b6805a05e0f422da883d796b8
MD5 cb90322281659dd427eb8f93e200110e
BLAKE2b-256 4ba924c0ea5b4837da3a434b0d0e49263df6bb86342f152edfc58fba38fcb3b5

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page