Error: Index exceeds matrix dimensions.
5 Ansichten (letzte 30 Tage)
Ältere Kommentare anzeigen
Cody Baumann
am 2 Apr. 2015
Beantwortet: Star Strider
am 3 Apr. 2015
clear
clc
[num,txt]=xlsread('tire_ratings.xls');
ratings=num(:,1);
speed=num(:,2);
vehicles =num(:,3);
text=txt(1,1:3);
TR=triangulation(ratings,speed,vehicles);
size(TR)
%This is the error/output
Index exceeds matrix dimensions.
Error in ENG1102_11C (line 9)
speed=num(:,2);
6 Kommentare
Akzeptierte Antwort
Star Strider
am 3 Apr. 2015
This works:
ratings=num(:,1);
speed=txt(:,1);
vehicles =txt(:,3);
The ‘num’ variable has one column, ‘txt’ has three, only 1 and 3 with any information.
0 Kommentare
Weitere Antworten (0)
Siehe auch
Kategorien
Mehr zu Matrix Indexing finden Sie in Help Center und File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!