May 2021 2 41 Report
How do convert a vector into a cell array?

Let's say I have res=cell(11,2); % to create a cell array with 11 rows and 2 columns

and I've written a function which gives me an output , for example vec=[3 4]

I tried this [res{2,1:2}]=vec to store my vec into the second row of the cell ray but it seems like it's not working even though both have 2 values. What's going on here? Please helpppp!!!!!

I keep getting a error saying too many output argument

Please enter comments
Please enter your name.
Please enter the correct email address.
You must agree before submitting.

Answers & Comments


Helpful Social

Copyright © 2024 QUIZLS.COM - All rights reserved.