spy
Sparsity-pattern plot of a sparse matrix.
Syntax
Section titled “Syntax”h = spy(s, c, sp)Description
Section titled “Description”Plots non-zero entries of s as markers on a 2D grid. Useful for visualizing sparse-matrix structure (banded, block-diagonal, fill-in, etc.).
Example
Section titled “Example”spy(sparse(magic(50)))