Create a cell with row vectors as elements
2 views (last 30 days)
Hi there! I am new to Matlab. I have ten 64x64x10 matrices named from A to J. What I want to do is to combine them so that each element of a new array is a vector containing the corresponding elements of each matrix (an array consisting of 64x64x10 10x1 vectors). So far I constructed such an array using the piece of code shown below. However, the problem is I wanted each cell to be represented by a column vector, not row vector. I also tried cellfun to transpose individual cells, but it seems not to work properly. Any advice would be highly appreciated.
S=arrayfun(@(a,b,c,d,e,f,g,h,i,j) num2str([a b c d e f g h i j]), A,B,C,D,E,F,G,H,I,J, 'un',0);