MATLAB Answers

0

I want to build a structure that includes multiple matrices

Asked by John Hunt on 14 Oct 2017
Latest activity Answered by Stephen Cobeldick on 14 Oct 2017
I want to build about 100 matrices that are just zeros that have three columns and one row.
I then want to populate these matrices with positions for a point that fits the criteria of each matrix (making the matrix start at 1 row to however many it ends up with).
how can I do that?

  0 Comments

Sign in to comment.

1 Answer

Answer by Stephen Cobeldick on 14 Oct 2017

A cell array would be simpler than a structure:
>> C = num2cell(zeros(100,3),2);
>> C{1}
ans =
0 0 0
>> C{2}
ans =
0 0 0
etc

  0 Comments

Sign in to comment.