diff --git a/Simple Linear Regression in Python/Simple+Linear+Regression+in+Python.ipynb b/Simple Linear Regression in Python/Simple+Linear+Regression+in+Python.ipynb index 5bef2ac..61b02ab 100644 --- a/Simple Linear Regression in Python/Simple+Linear+Regression+in+Python.ipynb +++ b/Simple Linear Regression in Python/Simple+Linear+Regression+in+Python.ipynb @@ -992,8 +992,8 @@ "metadata": {}, "outputs": [], "source": [ - "X_train_lm = X_train_lm.reshape(-1,1)\n", - "X_test_lm = X_test_lm.reshape(-1,1)" + "X_train_lm = X_train_lm.values.reshape(-1,1)\n", + "X_test_lm = X_test_lm.values.reshape(-1,1)" ] }, { @@ -1468,8 +1468,8 @@ "source": [ "# One aspect that you need to take care of is that the 'fit_transform' can be performed on 2D arrays only. So you need to\n", "# reshape your 'X_train_scaled' and 'y_trained_scaled' data in order to perform the standardisation.\n", - "X_train_scaled = X_train.reshape(-1,1)\n", - "y_train_scaled = y_train.reshape(-1,1)" + "X_train_scaled = X_train.values.reshape(-1,1)\n", + "y_train_scaled = y_train.values.reshape(-1,1)" ] }, {