/** * Size scales for proportional symbols and line widths. * * The default is `sqrt`, and that default is a correctness decision rather than a * preference. Readers judge a circle by its **area**, so mapping value linearly * to radius makes area grow with the square of the value: a country with ten * times the population gets a hundred times the ink. Square-root scaling makes * area proportional to value, which is the only encoding that reads honestly. * * `linear` is available because line widths and some designs genuinely want it, * and it warns in dev mode when used for symbol radii. * * @module scales/SizeScale */ import type { SizeLegendEntry, SizeOptions, SizeScaleType } from '../types'; export declare class SizeScale { readonly type: SizeScaleType; readonly domain: [number, number]; readonly range: [number, number]; readonly warnings: string[]; constructor(values: readonly (number | null | undefined)[], options?: SizeOptions); /** Normalised position of a value within the domain, 0..1. */ private position; /** Radius in screen pixels. Returns null for values that cannot be sized. */ radius(value: unknown): number | null; /** * Reference sizes for a nested-circle legend. * * Three circles at round values, drawn concentrically, is the only bubble legend * that lets a reader actually decode areas. Datawrapper does this well and * almost nobody else ships it at all. */ legendEntries(count?: number, format?: (v: number) => string): SizeLegendEntry[]; } export declare function createSizeScale(values: readonly (number | null | undefined)[], options?: SizeOptions): SizeScale; //# sourceMappingURL=SizeScale.d.ts.map