Skip to content

Documentation / @ripl/core / scaleBand

Function: scaleBand()

scaleBand<TDomain>(domain, range, options?): BandScale<TDomain>

Defined in: packages/core/src/scales/band.ts:34

Creates a band scale that maps discrete domain values to evenly spaced bands within the range.

Type Parameters

Type ParameterDefault type
TDomainstring

Parameters

ParameterType
domainTDomain[]
rangenumber[]
options?BandScaleOptions

Returns

BandScale<TDomain>