fixed issue with matrix of type vector
was being treated as list of vectors