What does this error mean?
1 回表示 (過去 30 日間)
古いコメントを表示
I keep getting an error saying that there is an "Unbalanced or unexpected parenthesis or bracket." This is the line I keep getting error on. What am I doing wrong?
for data(:,1:end)
0 件のコメント
採用された回答
Geoff Hayes
2014 年 11 月 9 日
The problem is the code is incorrectly defined for a for loop. If the intent is to iterate through each element of data(:,1:end), then your code should be written as
numRows = size(data,1);
for k=1:numRows
% get the kth row of data
rowData = data(k,:);
% do something with the row data
end
If that is not the intent of the code, then please describe what you are trying to do.
その他の回答 (0 件)
参考
カテゴリ
Help Center および File Exchange で Data Type Conversion についてさらに検索
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!