hi, i wanna size of a matrix but below error happens:
Indexing cannot yield multiple results.
Error in Untitle222d2 (line 2)
[N,M]=size(V)
OR
V =
1.0350 0.9710 0.9680
Subscript indices must either be real positive integers or logicals.
Error in Untitle222d2 (line 2)
N=size(V)
what does this means.

답변 (2개)

Walter Roberson
Walter Roberson 2021년 11월 26일

1 개 추천

You accidentally created a variable named "size"
Chetan Bhavsar
Chetan Bhavsar 2021년 11월 26일

0 개 추천

V= [ 1.0350 0.9710 0.9680]
V = 1×3
1.0350 0.9710 0.9680
[numRows,numCols] = size(V)
numRows = 1
numCols = 3
N=size(V)
N = 1×2
1 3
Working fine. You have some other query can you elaborate more please.

카테고리

도움말 센터File Exchange에서 Matrices and Arrays에 대해 자세히 알아보기

질문:

2021년 11월 26일

답변:

2021년 11월 26일

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by