how to fix Index exceeds matrix dimensions ?
Afficher commentaires plus anciens
for i=1:jumlah
filename=strcat('C:\Users\Documents\MATLAB\data\dataujiKW\',num2str(i),'.jpg');
image=imread(filename);
value=cast(extraction(image),'single'); %extraction is a function
counter=counter+1;
result{counter,1}=image;
for i=1:9
result{counter,i+1}=extraction(i);
end
hasilesktraksi=[result{i,2:10}]; // error
end
but, if i run in command window with command : hasilesktraksi=[hasiluji{1,2:10}], it not error and give the result. help please, thanks
4 commentaires
Image Analyst
le 7 Mai 2016
DO NOT use image as the name of your variable since it's the name of a very important built in function and you will destroy it.
ElizabethR
le 7 Mai 2016
Image Analyst
le 7 Mai 2016
I tried, below. Did you even see my answer below???
ElizabethR
le 7 Mai 2016
Modifié(e) : ElizabethR
le 7 Mai 2016
Réponse acceptée
Plus de réponses (0)
Catégories
En savoir plus sur Matrix Indexing dans Centre d'aide et File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!