From a6dddcf4e871e5ebf630e03bd8104e204f2e17c8 Mon Sep 17 00:00:00 2001 From: Donal Heidenblad Date: Thu, 16 Feb 2023 09:00:17 -0500 Subject: [PATCH] DecisionTree example no longer uses normalized data --- Chapter07/Chapter 7.ipynb | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/Chapter07/Chapter 7.ipynb b/Chapter07/Chapter 7.ipynb index 3a6ec1f..b42e55a 100644 --- a/Chapter07/Chapter 7.ipynb +++ b/Chapter07/Chapter 7.ipynb @@ -627,7 +627,9 @@ "\n", "classTree = DecisionTreeClassifier()\n", "classTree.fit(Xs, y)\n", - "\n", + "newApplicant = pd.DataFrame({'income': applicant_df.loc[20].income, \n", + " 'score': applicant_df.iloc[20].score},\n", + " index=[20])\n", "predict_y = classTree.predict(newApplicant)\n", "print(predict_y)" ]