create random matrix with 4 vectors
Afficher commentaires plus anciens
How can I create a random matrix X that has n rows, and each row is [1 0 0], [0 1 0], [0 0 1] or [0 0 0]. On top of that, the first possibility has to appear x times, the second one y times and the third one again z times. In other words sum(X)= [x y z]?
Réponse acceptée
Plus de réponses (0)
Catégories
En savoir plus sur Random Number Generation dans Centre d'aide et File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!