Randomly select a column

10 ビュー (過去 30 日間)
Md Nazmul Hoque
Md Nazmul Hoque 2022 年 6 月 4 日
コメント済み: Md Nazmul Hoque 2022 年 6 月 5 日
n= 3*100 matrix
i want to select 20 non repeating random column
so, final matrix will be
x=3*20 ;
where 3 rows should be the corresponding column value of the original matrix
Any help would be really appreciated.
Thanks
  2 件のコメント
Torsten
Torsten 2022 年 6 月 4 日
Md Nazmul Hoque
Md Nazmul Hoque 2022 年 6 月 5 日
sorry for that bro, i'm kinda new.
i wanted the specific solution.
in the last one , i thought i couldn't explain it properly
thats why. anyway thank you for your support.

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

採用された回答

Matt J
Matt J 2022 年 6 月 4 日
編集済み: Matt J 2022 年 6 月 4 日
x=n(:,randperm(100,20))
  1 件のコメント
Md Nazmul Hoque
Md Nazmul Hoque 2022 年 6 月 5 日
Thank you Bro.

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

その他の回答 (0 件)

カテゴリ

Help Center および File ExchangeCreating and Concatenating Matrices についてさらに検索

タグ

製品


リリース

R2021a

Community Treasure Hunt

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

Start Hunting!

Translated by