Read all the following instructions carefully.
A. In this assignment, you will learn how to fit a linear regression model to a dataset and how to evaluate it. You will be given a dataset, apartments.csv, that contains data from apartment rental listings for Los Angeles, California. It can be downloaded from Blackboard.
1. Load the dataset (apartments.csv) into a pandas DataFrame.
a. Calculate the sample correlation coefficients of the monthly rent (price) w.r.t to all the remaining features and print out the following:
i. one feature that is strongly correlated with price
ii. one feature that is weakly correlated with price
b. Build a simple linear model to predict the price given the size of the apartment (square_feet) using either the Scikit-learn Python library or the Keras and Tensorflow Python libraries. Tip: using Scikit-learn is the easier, more straight forward approach. (Hint: You will first need to initiate a model, then fit your model to the price and square feet columns from the DataFrame that you have loaded.)
c. Print out the slope and the intercept of the model.
d. Plot the line representation of this simple linear regression model, together with all the data points in the dataset using the two variables: price (on the y-axis) and square_feet (on the \( x \)-axis).
e. Given the square_feet of all the apartments in the dataset, make predictions of the price using the predictive model you have fitted in step 1.b. Print out all the predictions.
f. Evaluate your predictions by calculating and printing out the standard deviation of prediction errors by comparing your predictions with the true or ground-truth price shown in the dataset.