APPLICATION OF SUPERVISED LEARNING
MACHINE LEARNINGHARD QUESTIONS
Question
[CLICK ON ANY CHOICE TO KNOW THE RIGHT ANSWER]
|
k-NN algorithm does more computation on test time rather than train time.A) TRUE B) FALSE
|
True
|
|
False
|
|
Either A or B
|
|
None of the above
|
Explanation:
Detailed explanation-1: -The k-NN algorithm does more computation on test time rather than train time. That is absolutely true. The idea of the kNN algorithm is to find a k-long list of samples that are close to a sample we want to classify.
Detailed explanation-2: -So for KNN, the time complexity for Training is O(1) which means it is constant and O(n) for testing which means it depends on the number of test examples.
Detailed explanation-3: -In KNN, the training data points get stored, and no learning is performed. Validation data is to check the model performance, and the test data is used for prediction. To select optimal K, plot the error of model (error = 1-accuracy) on training as well as on the validation dataset.
There is 1 question to complete.