How can I create arrays with different names using loop?
9 views (last 30 days)
Show older comments
I want to create n=1:56 arrays with names a(n), and each array contein random number.
thank you.
0 Comments
Answers (1)
James Tursa
on 31 Mar 2022
Edited: James Tursa
on 31 Mar 2022
Don't embed numbering into the variable names. This will make the variables hard to use downstream in your code. Use cell arrays or multidimension arrays etc. instead. See this discussion:
0 Comments
See Also
Categories
Find more on Loops and Conditional Statements in Help Center and File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!