Interface RememberOpts<T>

    Options for remember. anchor is the fixed point sources scale about (a pivot, or the live centroid); feature is the writable scalar (a radius, mean distance, or sum).

    interface RememberOpts<T> {
        anchor: (vals: readonly T[]) => T;
        eps?: number;
        feature: (vals: readonly T[], anchor: T) => number;
        magnitude?: boolean;
        seed?: (vals: readonly T[]) => T[];
    }

    Type Parameters

    • T
    Index

    Properties

    anchor: (vals: readonly T[]) => T

    Point sources scale about — a constant pivot or a derived centroid.

    eps?: number

    Degeneracy threshold; below it the cluster is "collapsed" and the stored shape drives reinflation. Default 1e-9.

    feature: (vals: readonly T[], anchor: T) => number

    The scalar view (the forward): radius, mean radius, spread, sum, …

    magnitude?: boolean

    Feature is non-negative ⇒ a same-magnitude write (e.g. -r) is a no-op (PutGet on a magnitude). Default true; set false for a signed total.

    seed?: (vals: readonly T[]) => T[]

    Normalized shape to seed when the feature is degenerate at init and no prior good shape exists. Default: zero deviations (stays collapsed). totalLens passes uniform 1/K for an even split.