bandhic.band_hic_matrix.tocsr#

band_hic_matrix.tocsr()[source]#

Convert the matrix to CSR format.

Returns:

The matrix in scipy CSR sparse format.

Return type:

csr_array

Examples

>>> import bandhic as bh
>>> mat = bh.ones((3,3), diag_num=2)
>>> csr = mat.tocsr()
>>> csr.shape
(3, 3)