Transposing is fine! Thanks for that!

On Sunday, 20 July 2014, Odd Andersen <odd.ander...@gmail.com> wrote:

> Sparse matrices in Julia are to my understanding stored as compressed
> sparse columns.  So it is very easy to get the nonzero elements for a given
> column, but not so easy for rows.
>
> To get the indices of nonzeros rows for column 'c' in sparse matrix M, one
> can use (at least in the current implementation):
>
>  M.rowval[a.colptr[col] : M.colptr[col+1]-1]
>
> To do the same by rows would be more complicated (a quick-and-dirty
> solution would of course be to transpose your matrix first).
> I am however not a Julia expert, so perhaps there's a solution I am not
> aware of.
>
>

Reply via email to