MATLAB: I get this error? how can I solve it

returnindex

Error in returnindex (line 2) n=length(X);
Output argument "ind" (and maybe others) not assigned during call to "returnindex".
Error in BinData (line 28) Y(i,1)=returnindex(X(i),Value)-1;

Best Answer

Need your returnindex.m to see the problem. Most likely, it has a output argument called "ind" but was not assigned.
Related Question