how can i put multiple matrices into a struct?

 采纳的回答

A and B are maxtrixes of any size.
m=struct('matrix',{A,B});
struct field is 'matrix', so m(1).matrix == A and m(2).matrix == B.

1 个评论

Thanks!
So plugging in m(1).matrix in the command window will show me A, but what if A is also a struct with 2 matrices in them?

请先登录,再进行评论。

更多回答(0 个)

类别

帮助中心File Exchange 中查找有关 Structures 的更多信息

标签

Community Treasure Hunt

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

Start Hunting!

Translated by