How do I fix this error? Not enough input arguments.
Mostra commenti meno recenti
Im running this function:
function value = a_p(e)
%analysing power
a2 = [ ];
b2 = [ ];
%find value closest to randomly selected energy, e
[~,I] = min(abs(a2-e));
c2 = a2(I);
%find corresponding analysing power to that energy value
idx = find(a2 == c2);
bidx = b2(idx);
a_p = b2(idx);
value = a_p;
end
where a2 and b2 is just an array of data, I keep recieving the same error:
Not enough input arguments
Error in a_p (line 7)
[~,I] = min(abs(a2-e));
Risposta accettata
Più risposte (0)
Categorie
Scopri di più su Write Unit Tests in Centro assistenza e File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!