MATLAB: How to properly transpose a matrix

arrayMATLABmatrixtransposevector

I have a 1×31 vector array that I would like to transpose into a 31×1 vector. I set:
Array = Array';
However, every time I run the program, it switches between a row vector and a column vector. How can I get it to stay a column vector?

Best Answer

Regardless of the input size, this will give a column vector:
Array = Array(:)