how can i combine arrays of different size.
Show older comments
i have six arrays of size as given in figure.
i need to combine all arrays one after the other.
but the problem is they are of different dimenion.
how can i combine all these arrays?

thanks in advance.
4 Comments
Rik
on 31 May 2021
That depends on how you want to make them the same size. Do you want to pad them with zeros? Or with NaN? Or do you want to interpolate?
the cyclist
on 31 May 2021
Hm. You'll need to be more specific. For example, suppose your arrays were
A = [1 2 3 4;
5 6 7 8];
B = [1 2;
3 4;
5 6];
What should the combined array look like? Remember, numeric MATLAB arrays cannot have "empty spaces". But possibly you could pad with NaN. Or perhaps you need a cell array.
zhoug zho
on 31 May 2021
Accepted Answer
More Answers (0)
Categories
Find more on Creating and Concatenating Matrices 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!