I want to build a structure that includes multiple matrices

조회 수: 2 (최근 30일)
John Hunt
John Hunt 2017년 10월 14일
답변: Stephen23 2017년 10월 14일
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?

답변 (1개)

Stephen23
Stephen23 2017년 10월 14일
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

카테고리

Help CenterFile Exchange에서 Structures에 대해 자세히 알아보기

태그

Community Treasure Hunt

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

Start Hunting!

Translated by