Hi Guys,
I was using this code line for concatenate a [8 x 4 x 6] matrix in a [16 x 2 x 6] matrix:
X = [x(:,1:2,:); x(:,3:4,:)];
Now, I am trying to convert a [200 x 200 x 11] matrix in a [40000 x 2 x 11] matrix, using the code line before mentioned:
X = [x(:,1:2,:); x(:,3:4,:); x(:,5:6,:); x(:,7:8,:); x(:,9:10,:); x(:,11:12,:); x(:,13:14,:); x(:,15:16,:); x(:,17:18,:); x(:,19:20,:); …
(and so on)
x(:,181:182,:); x(:,183:184,:); x(:,185:186,:); x(:,187:188,:); x(:,189:190,:); x(:,191:192,:); x(:,193:194,:); x(:,195:196,:); x(:,197:198,:); x(:,199:200,:)];
It works, but I can do the same with a for loop (or another approach), and for general matrix array?
[I x J*2 x K] to [I*J x 2 x K]
Thanks for your help in advance.
Best Answer