Hi gyus, I am a beginner in coding.
My problem is that I want to find indices of values using a loop, but having and error.
Could anyone explain what is wrong with loop and give a solution??? (file which I use is attached)
The general idea is to find 5 smallest values and its indices from the dataset (column "Lag").
clear;data=xlsread('kNN_300_y_pred_wd XYZValue + lag.csv'); newarray = sort(data(:,5));k=5;values = newarray(1:k);for i=1:k index = find(values==data(:,5));end
Best Answer