MATLAB: How to measure how long it takes to run on test set

machine learningMATLAB

% Make a prediction for the test set
Y_knn = knn.predict(Xtest);
Related Question