GCXS.to_scipy_sparse

GCXS.to_scipy_sparse(accept_fv=None)[source]

Converts this GCXS object into a scipy.sparse.csr_matrix or scipy.sparse.csc_matrix.

Parameters:

accept_fv (scalar or list of scalar, optional) – The list of accepted fill-values. The default accepts only zero.

Returns:

The converted Scipy sparse matrix.

Return type:

scipy.sparse.csr_matrix or scipy.sparse.csc_matrix

Raises:
  • ValueError – If the array is not two-dimensional.

  • ValueError – If all the array doesn’t zero fill-values.