Orange Forum • View topic - Documentation Bug: KNN Trains and Tests on Same Data

Documentation Bug: KNN Trains and Tests on Same Data

Report bugs (or imagined bugs).
(Archived/read-only, please use our ticketing system for reporting bugs and their discussion.)
Forum rules
Archived/read-only, please use our ticketing system for reporting bugs and their discussion.

Documentation Bug: KNN Trains and Tests on Same Data

Postby Valiant » Tue Jul 27, 2004 17:26

In the KNN documentation, the KNN learner trains on the full IRIS dataset, and then tests on a random training sample. This explains why the classifier is *always* perfect. A better technique would be to use the orngTest.crossValidation function.[/url]

Postby Janez » Tue Jul 27, 2004 17:52

Thanks. I don't know what I was thinking when I wrote that :)

Fixed it. The idea is not to check the classification accuracy, so there's not point using cross validation - I've just separated the data set for learning, so that the results are more credible. And the classification is still perfect, since the classes are indeed well separated.

Janez


Return to Bugs