@ai-on-browser/data-analysis-models
    Preparing search index...

    Adaptive Metric Nearest Neighbor

    Index

    Constructors

    Properties

    Methods

    Constructors

    • Parameters

      • Optionalk0: number

        The number of neighbors of the test point

      • Optionalk1: number

        The number of neighbors in N1 for estimation

      • Optionalk2: number

        The size of the neighborhood N2 for each of the k0 neighbors for estimation

      • Optionall: number

        The number of points within the delta intervals

      • Optionalk: number

        The number of neighbors in the final nearest neighbor rule

      • Optionalc: number

        The positive factor for the exponential weighting scheme

      Returns ADAMENN

    Properties

    _c: number
    _classes: any[]
    _itr: number
    _k: number
    _k0: number
    _k1: number
    _k2: number
    _l: number
    _x: number[][]
    _y: any[]

    Methods

    • Parameters

      • a: any
      • b: any
      • w: any

      Returns number

    • Fit model.

      Parameters

      • x: number[][]

        Training data

      • y: any[]

        Target values

      Returns void

    • Returns predicted categories.

      Parameters

      • datas: number[][]

        Sample data

      Returns any[]

      Predicted values