update readme with new chapter links

This commit is contained in:
franzi
2021-09-22 10:31:53 +02:00
parent a2875b338a
commit f6017bc1ed
2 changed files with 22 additions and 22 deletions

View File

@@ -187,10 +187,10 @@
"source": [
"## Linear Models\n",
"\n",
"After reading the chapter on linear models, test them here on different datasets (by changing the number at the end of the dataset variable, e.g., `X_reg_2` -> `X_reg_3`) and experiment with their hyperparameter settings (in the comments you'll find a description of the different hyperparameters and which values you can test for them).\n",
"After reading the chapter on linear models, test them here on different datasets (by changing the number at the end of the dataset variable, e.g., `X_reg_1` -> `X_reg_2`) and experiment with their hyperparameter settings (in the comments you'll find a description of the different hyperparameters and which values you can test for them).\n",
"\n",
"**Questions:**\n",
"- Compare the linear regression and ridge regression models on the regression dataset with outliers: what do you observe?\n",
"- Compare the linear regression and ridge regression models on the regression dataset with outliers (i.e., `X_reg_2, y_reg_2`): what do you observe?\n",
"- What happens when you increase the value for `alpha` for the ridge regression model? (first think about it, then confirm your guess by actually changing the parameter)"
]
},
@@ -210,7 +210,7 @@
"outputs": [],
"source": [
"# Linear Regression\n",
"X, y = X_reg_2, y_reg_2 # change the numbers here to test the model on a different dataset\n",
"X, y = X_reg_1, y_reg_1 # change the numbers here to test the model on a different dataset\n",
"model = LinearRegression()\n",
"model.fit(X, y)\n",
"plot_regression(X, y, model)\n",
@@ -225,7 +225,7 @@
"source": [
"# Ridge Regression:\n",
"# alpha (> 0): regularization (higher values = more regularization)\n",
"X, y = X_reg_2, y_reg_2\n",
"X, y = X_reg_1, y_reg_1\n",
"model = Ridge(alpha=1.)\n",
"model.fit(X, y)\n",
"plot_regression(X, y, model)\n",