Is it possible to get a matrix column by name from a matrix?
I tried various approaches such as myMatrix["test", ]
but nothing seems to work.
Yes. But place your "test" after the comma if you want the column...
> A <- matrix(sample(1:12,12,T),ncol=4)
> rownames(A) <- letters[1:3]
> colnames(A) <- letters[11:14]
> A[,"l"]
a b c
6 10 1
see also help(Extract)