Limiting vectors to a certain number of rows
Infos
Cette question est clôturée. Rouvrir pour modifier ou répondre.
Afficher commentaires plus anciens
Hi, i have created a function that creates n lots of a matrix of 3 columns but different number of rows. How do i limit the number of rows of this matrixes to say 4 for each one?
Réponses (1)
Andrei Bobrov
le 12 Déc 2013
n = 7;
out = arrayfun(@(x)rand(randi(4),3),1:n,'un',0);
Cette question est clôturée.
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!