Do you expect there to be a Vector constructor from SparseMatrixCSC? Do you want it to contain the storage column, or each element of the represented matrix?
If it’s the first, I think x.colptr does the trick.
Btw, of you write a self-contained example it’s much easier to debug. I don’t have access to your file.
Thanks for the hint. I am digging more into the documentation of Sparse Arrays. c.mtx stores a column vector that I generate from another application. After reading, dump(c) returns
I think Vector(c) should give me the vector object with sparse entry as specified in SparseMatrixCSC. My code works for when c is constructed within Julia (of different type then SparseMatrixCSC i think).
What do you need it for? There is vec(x), but that doesn’t create a real vector either (luckily, because that’s a lot of zeros). Most applications should be able to just use the SparseMatrixCSC directly.
The other way to think of this is, your object represents an n \times 1 matrix, not a vector. Matrix(x) works. If you want a vector, you should be using SparseVector, which does have a constructor from SparseMatrixCSC