MATLAB: How to create a 4 dimensional array?

arrayMATLAB

This is just a general question because I can't find it anywhere, but does anyone know how to create a 4-D array? What would the basic code be for it or just a basic example of one would be great!

Best Answer

Supposing A and B are 3 dimensional arrays, then cat(4,A,B) would join them along the fourth dimension.