Linear regression is the fundamental building block of data science and analytics. If you ever venture into data science, this will most likely be the first model you're taught.
This lesson is aimed at those with no experience in data science or programming. It's also designed to teach you what a linear regression is, and how to write a regression model within Scikit-Learn.
The instructions below will walk through the necessary software requirements to complete the lesson.
Download and install Anaconda. For this exercise, download the Python 2.7 version.
Open the Terminal application. Then, type the following code.
python
from sklearn import datasets, linear_model
from sklearn.metrics import mean_squared_error, r2_score
Launch the command line. Then, type the following code.
python
from sklearn import datasets, linear_model
from sklearn.metrics import mean_squared_error, r2_score