import { ClassifierBase } from '../base'; import { Params } from '../base/estimator'; import { Distance } from '../metrics'; import { IWeightType } from './utils'; export interface KNearestNeighborsProps { kNeighbors?: number; weightType?: IWeightType; distanceType?: Distance.IDistanceType; pNorm?: number; } export declare class KNearestNeighbors extends ClassifierBase { private trainX; private trainY; private metric; private kNeighbors; private weightType; private pNorm; private fitted; constructor(props?: KNearestNeighborsProps); /** @deprecated positional form; prefer the props-object constructor */ constructor(kNeighbors?: number, weightType?: IWeightType, distanceType?: Distance.IDistanceType, pNorm?: number); getParams(): Params; fit(trainX: number[][], trainY: number[]): void; predict(testX: number[][]): number[]; } /** @deprecated Use KNearestNeighbors instead. */ export declare const KNearstNeighbors: typeof KNearestNeighbors; /** @deprecated Use KNearestNeighbors instead. */ export type KNearstNeighbors = KNearestNeighbors;