How to extract a value from a Row or Column vector?

51 ビュー (過去 30 日間)
Sean St Cyr
Sean St Cyr 2020 年 6 月 23 日
コメント済み: SCE 2024 年 2 月 27 日
Im trying to take the 5th value of a randomly generated row or column vector. How would I write the code for that?
  2 件のコメント
Star Strider
Star Strider 2020 年 6 月 23 日
See the documentation on Matrix Indexing for details.
Is this as homework assignment?
SCE
SCE 2024 年 2 月 27 日
A= V(5)
Simply write this!:)

サインインしてコメントする。

採用された回答

Fangjun Jiang
Fangjun Jiang 2020 年 6 月 23 日
Is this what you are looking for ?
MyVector=rand(100,1);
MyData=MyVector(5);
  2 件のコメント
Star Strider
Star Strider 2020 年 6 月 23 日
I suspect this is a homework assignment.
David Randolph
David Randolph 2022 年 5 月 13 日

サインインしてコメントする。

その他の回答 (0 件)

カテゴリ

Help Center および File ExchangeGet Started with MATLAB についてさらに検索

Community Treasure Hunt

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

Start Hunting!

Translated by