Documentation / @finchart/core / index / AreaSeries
Class: AreaSeries<T>
Defined in: packages/core/src/series/area-series.ts:64
A series that fills below its line down to the bottom of the plot. A gap splits the fill too — the fill follows the same rule as the line breaking at a gap. One polygon per run of unbroken values.
The accessor is injected, for the same reason as LineSeries: drawing a close-price area over OHLC is areaSeries({ coordinates: new OHLCAccessor() }).
Type Parameters
T
T extends BaseDataPoint = LineDataPoint
Implements
Series<T>
Constructors
Constructor
new AreaSeries<
T>(options):AreaSeries<T>
Defined in: packages/core/src/series/area-series.ts:70
Parameters
options
Returns
AreaSeries<T>
Properties
coordinates
readonlycoordinates:CoordinateAccessor<T>
Defined in: packages/core/src/series/area-series.ts:67
How to read coordinates from its own point. Omitted means reading x and y directly. It's here for the same reason as decimation — a candle's value is close (OHLC has no y), and only the candle knows that.
Implementation of
Methods
draw()
draw(
target,context):void
Defined in: packages/core/src/series/area-series.ts:89
Parameters
target
context
Returns
void
Implementation of
valueExtent()
valueExtent(
data):Range|null
Defined in: packages/core/src/series/area-series.ts:75
The range this representation occupies on the y axis. A line is a single point, so min === max, but a candle occupies a low-to-high span — that can't be expressed as a single number, so it returns a Range.
null when there's nothing to measure — returning { min: 0, max: 0 } would let a series whose data hasn't arrived yet drag the value axis down to 0.
Parameters
data
DataView<T>
Returns
Range | null