Implementation of different ML algorithms for learning purpose
This repository contains implementations of common Machine Learning Algorithms and related functionality. This exercise is to improve my understanding of these algorithms and not for production-ready implementations.
Simple Linear Regression is the most basic algorithm for regression problems where there is 1 continuous, dependent variable and 1 continuous, independent variable. This algorithm is used to arrive at a linear relationship between the dependent and independent variables. The solution for the coefficients can be arrived at by application of basic linear algebra.
Implementation
Using matrix functions from Numpy library and linear algebra solution for coefficients, the implementation is extremely simple using Sxx and Sxy, where
Sxx is the sum of the squares of the difference between each x and the mean x value,
and Sxy is the sum of the product of the difference between x its means and the difference between y and its mean
TODO:
Implement predictions
Refractor to fit-predict interface
Additonal statistics
Work through algebraic proof
Write article on Medium