@graphty/algorithms / index / SpectralResult
Interface: SpectralResult ​
Defined in: indexed/spectral.ts:34
Result of the index-based spectral clustering.
Extends ​
Properties ​
converged ​
readonlyconverged:boolean
Defined in: indexed/spectral.ts:45
Whether the eigenpairs met the residual tolerance. False when the iteration stopped at its round cap -- on a graph whose small eigenvalues crowd together, such as a long path -- and the eigenpairs are then approximations (the labels usually still hold). True when there were no eigenpairs to compute.
count ​
readonlycount:number
Defined in: indexed/components.ts:11
Number of distinct labels.
Inherited from ​
eigenvalues ​
readonlyeigenvalues:Float64Array
Defined in: indexed/spectral.ts:36
The k smallest eigenvalues of the Laplacian, ascending; empty when k >= nodeCount.
eigenvectors ​
readonlyeigenvectors:Float64Array<ArrayBufferLike>[]
Defined in: indexed/spectral.ts:38
One nodeCount-long eigenvector per eigenvalue; for randomWalk, of I - D^-1 A.
labels ​
readonlylabels:U32
Defined in: indexed/components.ts:9
Dense label per node index, in first-seen order.
Inherited from ​
Methods ​
groups() ​
groups():
U32[]
Defined in: indexed/components.ts:16
Node indices grouped by label, computed once and cached.
Returns ​
U32[]
One array per label