This project demonstrates a simple implementation of linear regression using gradient descent in Python, applied to a subset of the famous Iris dataset.
We use only the data points where the Iris species is of class 0 (setosa), and perform regression between:
- Feature: Sepal length (cm)
- Target: Sepal width (cm)
- Manual implementation of:
- Mean Squared Error (MSE)
- Gradient of cost function
- Iterative updates to weights (slope) and bias
- Visualization of data points and regression line
Linear Regression.ipynb: Jupyter notebook containing all code, plots, and step-by-step execution.
- Numpy
- Pandas
- Matplotlib
- Scikit-learn