next up previous contents
Next: Memory Based Learning Up: Nearest neighbor Previous: Nearest neighbor

A note on the graphing options

The function approximated by nearest neighbor should pass through all the data points except cases where two data points have exactly the same input, but different outputs. If you look carefully at Vizier's nearest neighbor plot of j1.mbl, you'll notice that it doesn't really pass through all the points in the data set. The line drawn on the graph was generated by computing the value of the approximated function at a discrete number of points and drawing a line through those points. The default number of points is 60, which you can see in the graph dialogue box with the label ``resolution''. To see a more accurate graph of the function, increase this number to 500 and graph it again.

File -> Open -> j1.mbl
Model -> Graph -> Resolution  500
               -> Graph

You'll note that the new graph is more accurate, but takes significantly longer to compute. The default values are reasonable for many graphs, but you can always adjust them to trade off accuracy and compute time.



Jeff Schneider
Fri Feb 7 18:00:08 EST 1997