Skip to content

@graphty/algorithms / index / SpectralOptions

Interface: SpectralOptions ​

Defined in: indexed/spectral.ts:18

Options of the index-based spectral clustering.

Properties ​

k ​

readonly k: number

Defined in: indexed/spectral.ts:20

Number of clusters, a positive integer.


laplacianType? ​

readonly optional laplacianType?: LaplacianType

Defined in: indexed/spectral.ts:22

D - A, I - D^-1/2 A D^-1/2 (rows of the embedding scaled to unit length) or I - D^-1 A; default normalized.


maxIterations? ​

readonly optional maxIterations?: number

Defined in: indexed/spectral.ts:24

Cap on k-means rounds; default 100.


seed? ​

readonly optional seed?: number

Defined in: indexed/spectral.ts:28

Seed of the starting block and of the k-means seeding; default 42.


tolerance? ​

readonly optional tolerance?: number

Defined in: indexed/spectral.ts:26

k-means stops when no centroid moves further than this; default 1e-4.


weights? ​

readonly optional weights?: NumericVector

Defined in: indexed/spectral.ts:30

Per-arc weight override, arcCount long -- the facade passes expandEdges(s, shadow.data).