kepler.gl
Version:
kepler.gl is a webgl based application to visualize large scale location data in the browser
24 lines (23 loc) • 1 kB
TypeScript
import { DataContainerInterface } from './data-container-interface';
declare type dataValueAccessor = <T>(param: T) => T;
declare type dataContainerValueAccessor = (d: {
index: number;
}, dc: DataContainerInterface) => any;
declare type sort = (a: any, b: any) => any;
/**
* return quantile domain for an array of data
*/
export declare function getQuantileDomain(data: any[], valueAccessor?: dataValueAccessor, sortFunc?: sort): number[];
/**
* return ordinal domain for a data container
*/
export declare function getOrdinalDomain(dataContainer: DataContainerInterface, valueAccessor: dataContainerValueAccessor): string[];
/**
* return linear domain for an array of data
*/
export declare function getLinearDomain(data: number[], valueAccessor?: dataValueAccessor): [number, number];
/**
* return linear domain for an array of data. A log scale domain cannot contain 0
*/
export declare function getLogDomain(data: any[], valueAccessor: dataValueAccessor): [number, number];
export {};