Unable to perform assignment because the left and right sides have a different number of elements.

1 回表示 (過去 30 日間)

採用された回答

Jon
Jon 2020 年 2 月 11 日
編集済み: Jon 2020 年 2 月 11 日
In your expression, the left hand side is just a scalar (only has one element) but you are trying to assign a length 4 column vector to it. This doesn't make sense.
It would be much simpler just to make your "100 sets of 4 random #'s" using one line in MATLAB
D = normrnd(50,10,[4,100])
This will produce a 4 by 100 matrix, where each column is a set of 4 random numbers

その他の回答 (0 件)

カテゴリ

Help Center および File ExchangeLogical についてさらに検索

タグ

Community Treasure Hunt

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

Start Hunting!

Translated by