Skip to content

ZohaibSattarDataAI/Machine-Learning-From-Scratch

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

269 Commits
 
 
 
 
 
 

Repository files navigation

🤖 Machine Learning From Scratch

Welcome to Machine Learning From Scratch — a comprehensive, beginner-friendly, and professional repository containing classic Machine Learning algorithms implemented in two ways:

From Scratch (Pure Python) — for complete understanding of the math and logic
With Scikit-learn — for production-ready and fast implementation

📌 This project includes only Machine Learning algorithms (no deep learning), with clean code, real datasets, and Jupyter notebooks for practice.


Machine Learning Algorithum

Link:Machine Learning From Scratch


🎯 Project Mission

To help students, developers, and AI enthusiasts learn Machine Learning the right way — by implementing core algorithms manually and then applying the same models using Scikit-learn for practical use.


🧠 Algorithms Included

Each folder includes:

  • Python code (from scratch)
  • Scikit-learn version
  • Dataset(s)
  • Jupyter notebook(s)

🔹 Supervised Learning

📈 Regression

  1. ✅ Simple Linear Regression
  2. ✅ Polynomial Linear Regression
  3. ✅ Multiple Linear Regression
  4. ✅ Lasso Regression
  5. ✅ Ridge Regression
  6. ✅ Random Forest Regression
  7. ✅ XGBoost Regressor (Scikit-learn version only)
  8. ✅ Decision Tree Regressor
  9. ✅ LightGBM Regressor
  10. ✅ CatBoost Regression
  11. ✅ ElasticNet Regression
  12. ✅ Bayesian Ridge Regression
  13. ✅ Gradient Boosting Regression
  14. ✅ Support Vector Machine (SVM) Regression
  15. ✅ K-Nearest Neighbors (KNN) Regression
  16. ✅ Huber Regression
  17. ✅ Orthogonal Matching Pursuit (OMP)
  18. ✅ Theil-Sen Regression
  19. ✅ Quantile Regression
  20. ✅ Tweedie Regression
  21. ✅ Principal Component Regression (PCR)
  22. ✅ Gamma Regression
  23. ✅ AdaBoost Regression
  24. ✅ Stepwise Regression
    • i) Forward Stepwise
    • ii) Backward Stepwise

🔍 Classification

  1. ✅ Logistic Regression
  2. ✅ Random Forest Classification
  3. ✅ Decision Tree Classification
  4. ✅ LightGBM Classification
  5. ✅ K-Nearest Neighbors Classification (KNN)
  6. ✅ Support Vector Machine Classification (SVM)
  7. ✅ Gaussian Naive Bayes Classification
  8. ✅ Bernoulli Naive Bayes Classification
  9. ✅ Multinomial Naive Bayes Classification
  10. ✅ AdaBoost Classification
  11. ✅ CatBoost Classification
  12. ✅ XGBoost Classification
  13. ✅ Gradient Boosting Classification
  14. ✅ Extra Tree Classification
  15. ✅ Linear Discriminant Analysis (LDA)

🔹 Unsupervised Learning

  • ✅ K-Means Clustering
  • ✅ Hierarchical Clustering
  • ✅ DBSCAN
  • ✅ PCA (Principal Component Analysis)
  • ✅ Apriori Algorithm (Association Rule Mining)
  • ✅ Frequent Pattern Growth (FP-Growth)


📘 Requirements

  • Python 3.x
  • NumPy, Pandas, Matplotlib, Seaborn
  • Scikit-learn (for sklearn versions only)

Install dependencies:

pip install numpy pandas matplotlib seaborn scikit-learn

💼 Use Cases

This repository is perfect for:

  • Students learning ML theory and code
  • Preparing for interviews and exams
  • Building data science portfolios
  • Training models with real datasets

🙌 Author

Zohaib Sattar
📧 Email: zabizubi86@gmail.com 🔗 LinkedIn: Zohaib Sattar


⭐️ Support the Project

If you find this project helpful, please ⭐️ star the repo and share it with your network. It motivates further open-source contributions!