Path: blob/master/april_18/lessons/lesson-08/code/starter-code/starter-code-8.ipynb
1905 views
Kernel: Python 2
In [ ]:
In [ ]:
In [ ]:
In [ ]:
Starter Code
Work on improving the classifier below.
In [ ]:
Using distance: KNN implementation
In [ ]:
Do we see a change in performance when using the distance weight?
In [ ]:
Solution to solving K
This is only one approach to the problem, but adding in the 'distance' parameter (instead of uniform) would only be additive. Note the code would need some editing to handle it properly if done in the grid search; alternatively, make the change directly in the estimator.
In [ ]:
In [ ]: