Randomly select a column
10 visualizzazioni (ultimi 30 giorni)
Mostra commenti meno recenti
Md Nazmul Hoque
il 4 Giu 2022
Commentato: Md Nazmul Hoque
il 5 Giu 2022
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 Commenti
Torsten
il 4 Giu 2022
Why do you ask the same question again ?
Here is (again) the answer:
x=n(:,sort(randperm(100,20)))
Più risposte (0)
Vedere anche
Categorie
Scopri di più su Creating and Concatenating Matrices in Help Center e File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!