scipy.sparse.csc_matrix.nnz

csc_matrix.nnz

Get the count of explicitly-stored values (nonzeros)

Parameters:

axis : None, 0, or 1

Select between the number of values across the whole matrix, in each column, or in each row.

Previous topic

scipy.sparse.csc_matrix

Next topic

scipy.sparse.csc_matrix.has_sorted_indices