how to repeat specific rows?

I have a cell array and would like to repeat certain rows. how do I do this?

Answers (1)

Something like this?
C = {'hello' ; rand(2,3) ; 1:5, 6}
ix = [1 1 2 3 3 3 4]
C = C(ix)

Categories

Tags

Asked:

on 4 Mar 2014

Answered:

on 4 Mar 2014

Community Treasure Hunt

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

Start Hunting!