Selecting a subset of a larger matrix with criteria
Mostra commenti meno recenti
Hi,
I have a matrix that is Nrows x 150000 that includes a small number values that are less than or equal to -1. I would like to create a smaller Nrows x 100000 matrix that only includes values greater than -1 using a random subset of the remaining values in the larger matrix. It could also be the first 100000 values in each row that fit the criteria, but it cannot be, for example, the largest 100000 values, as this would introduce bias. Therefore, I have not been able to figure this it out by sorting the values. It is also complicated by the fact that each row has a different number of values that are <=-1, so I can't simply drop those values; it would create a matrix with different numbers of columns.
Please help! And thank you in advance. Noah
Risposta accettata
Più risposte (0)
Categorie
Scopri di più su Gravitation, Cosmology & Astrophysics in Centro assistenza e File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!