Skip to content

Commit bb222bd

Browse files
committed
Fix off-by-one error
1 parent d6e35da commit bb222bd

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

07_ensemble_learning_and_random_forests.ipynb

+1-1
Original file line numberDiff line numberDiff line change
@@ -1683,7 +1683,7 @@
16831683
"plt.figure(figsize=(10, 4))\n",
16841684
"\n",
16851685
"plt.subplot(121)\n",
1686-
"plt.plot(errors, \"b.-\")\n",
1686+
"plt.plot(np.arange(1, len(errors) + 1), errors, \"b.-\")\n",
16871687
"plt.plot([bst_n_estimators, bst_n_estimators], [0, min_error], \"k--\")\n",
16881688
"plt.plot([0, 120], [min_error, min_error], \"k--\")\n",
16891689
"plt.plot(bst_n_estimators, min_error, \"ko\")\n",

0 commit comments

Comments
 (0)