Skip to content Skip to sidebar Skip to footer

Regression Using Python

I have the following variables: import numpy as np import pandas as pd import matplotlib.pyplot as plt from sklearn.model_selection import train_test_split np.random.seed(0) n =

Solution 1:

The return statement should be performed after the for is done, so it should be indented under the for, not further in.

Solution 2:

At the start of your line

n = 15

You stopped with identing. So that part isn't recognized as the function. This can be solved by putting 4 spaces on all lines from n = 15 onwards.

Post a Comment for "Regression Using Python"