UNPKG

823 BTypeScriptView Raw
1import { Threshold } from './threshold';
2import { QuantileOptions, Range } from '../types';
3/**
4 * 类似 Threshold 比例尺,区别在于分位数比例尺 (Quantile) 将一个离散的输入域映射到一个离散的输出域
5 * 输入域被指定为一组离散的样本值,输出域中的值的数量决定了分位数的数量。
6 */
7export declare class Quantile extends Threshold<QuantileOptions> {
8 private thresholds;
9 protected getDefaultOptions(): QuantileOptions;
10 constructor(options?: QuantileOptions);
11 protected getDomain(): number[];
12 protected rescale(): void;
13 /**
14 * 如果是在第一段后或者最后一段就把两端的值添加上
15 */
16 invert(y: Range<QuantileOptions>): number[];
17 getThresholds(): number[];
18 clone(): Quantile;
19 getTicks(): number[];
20}