One thing that is annoying in Mathematica is, selecting parts of a Matrix creates lists that do not retain the matrix structure.
For example, in MATLAB if you do:
A=rand(10,10) and then
a=A(:,1)
You will get sizes of (10 10) and (10 1) matrices respectively.
The analog operation in Mathematica produces:
A = RandomReal({}, {10, 10}); A // Dimensions
A((;; , 1)) // Dimensions
{10,10} and {10} respectively.
What is the right way to select the first column of A such that I get a matrix with dimensions {10,1} like I would in MATLAB?
I know that I can do
{A((;;,1))}^:ct:
To achieve this but this feels wrong and there should be a simple way I do not know.