Which function will tell me how many rows and columns in matrix?
2 ビュー (過去 30 日間)
古いコメントを表示
How would I be able to write row(A) and it would output the number of rows in matrix A?
What function should I use and write? Same with columns?
Thanks.
0 件のコメント
回答 (1 件)
Image Analyst
2014 年 5 月 18 日
編集済み: Image Analyst
2014 年 5 月 18 日
theDimensionSizes = size(A);
numDims = ndims(A);
for d = 1 : numDims
fprintf('Dimension #%d is %d long.\n', k, theDimensionSizes(k));
end
0 件のコメント
参考
カテゴリ
Help Center および File Exchange で Simulated Annealing についてさらに検索
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!