Skip to content

Interface: YAxisOptions ​

Defined in: plot.ts:82

Extends ​

Properties ​

addTicks? ​

ts
optional addTicks?: (number | Tick)[];

Defined in: types.ts:23

Extra ticks layered on top of the auto ticks (only used when ticks is not set).

Inherited from ​

AxisConfig.addTicks


axisLineColor? ​

ts
optional axisLineColor?: string;

Defined in: types.ts:35

Axis line color. Default: the per-axis color, else theme.axis.

Inherited from ​

AxisConfig.axisLineColor


axisLineWidth? ​

ts
optional axisLineWidth?: number;

Defined in: types.ts:37

Axis line width in px. Default 1.

Inherited from ​

AxisConfig.axisLineWidth


color? ​

ts
optional color?: string;

Defined in: plot.ts:92

Axis + label color (secondary axes often match their series).


domain? ​

ts
optional domain?: Range;

Defined in: plot.ts:84


factors? ​

ts
optional factors?: string[];

Defined in: plot.ts:86

Factor labels for a "categorical" axis.


format? ​

ts
optional format?: (value) => string;

Defined in: types.ts:25

Formats a numeric tick value into a label when the tick has no explicit label.

Parameters ​

ParameterType
valuenumber

Returns ​

string

Inherited from ​

AxisConfig.format


gridColor? ​

ts
optional gridColor?: string;

Defined in: types.ts:61

Major grid line color. Default theme.grid.

Inherited from ​

AxisConfig.gridColor


gridDash? ​

ts
optional gridDash?: number[];

Defined in: types.ts:65

Grid line dash pattern (Canvas setLineDash). Default solid.

Inherited from ​

AxisConfig.gridDash


gridMinorColor? ​

ts
optional gridMinorColor?: string;

Defined in: types.ts:67

Minor grid line color. Default theme.gridMinor.

Inherited from ​

AxisConfig.gridMinorColor


gridWidth? ​

ts
optional gridWidth?: number;

Defined in: types.ts:63

Grid line width in px. Default 1.

Inherited from ​

AxisConfig.gridWidth


labelColor? ​

ts
optional labelColor?: string;

Defined in: types.ts:47

Tick label color. Default: the per-axis color, else theme.text.

Inherited from ​

AxisConfig.labelColor


labelFont? ​

ts
optional labelFont?: string;

Defined in: types.ts:49

Tick label font (CSS font shorthand). Default theme.font.

Inherited from ​

AxisConfig.labelFont


labelRotation? ​

ts
optional labelRotation?: number;

Defined in: types.ts:51

Rotate tick labels by this many degrees. Default 0.

Inherited from ​

AxisConfig.labelRotation


labelStandoff? ​

ts
optional labelStandoff?: number;

Defined in: types.ts:53

Gap in px between a tick and its label. Default 3.

Inherited from ​

AxisConfig.labelStandoff


minorTicks? ​

ts
optional minorTicks?: number | boolean;

Defined in: types.ts:27

Auto minor ticks: true for a default count, or a number of subdivisions per major interval.

Inherited from ​

AxisConfig.minorTicks


showAxisLine? ​

ts
optional showAxisLine?: boolean;

Defined in: types.ts:33

Draw the axis line. Default true.

Inherited from ​

AxisConfig.showAxisLine


showGrid? ​

ts
optional showGrid?: boolean;

Defined in: types.ts:59

Draw grid lines for this axis. Default true.

Inherited from ​

AxisConfig.showGrid


showTicks? ​

ts
optional showTicks?: boolean;

Defined in: types.ts:39

Draw tick marks. Default true.

Inherited from ​

AxisConfig.showTicks


side? ​

ts
optional side?: "left" | "right";

Defined in: plot.ts:90

Which side to draw the axis on. Default "right" for secondary axes.


tickColor? ​

ts
optional tickColor?: string;

Defined in: types.ts:41

Tick mark color. Default: the per-axis color, else theme.axis.

Inherited from ​

AxisConfig.tickColor


tickLength? ​

ts
optional tickLength?: number;

Defined in: types.ts:43

Major tick length in px. Default 5 (minor ticks are 3).

Inherited from ​

AxisConfig.tickLength


ticks? ​

ts
optional ticks?: TicksSpec;

Defined in: types.ts:21

Ticks: an array of positions, an array of Tick objects, or a generator fn.

Inherited from ​

AxisConfig.ticks


tickWidth? ​

ts
optional tickWidth?: number;

Defined in: types.ts:45

Tick mark line width in px. Default 1.

Inherited from ​

AxisConfig.tickWidth


times? ​

ts
optional times?: ArrayLike<number>;

Defined in: plot.ts:88

Per-index epoch-ms timestamps for an "ordinal-time" axis.


title? ​

ts
optional title?: string;

Defined in: types.ts:29

Axis title, drawn along the axis.

Inherited from ​

AxisConfig.title


titleColor? ​

ts
optional titleColor?: string;

Defined in: types.ts:55

Axis title color. Default: the per-axis color, else theme.text.

Inherited from ​

AxisConfig.titleColor


titleFont? ​

ts
optional titleFont?: string;

Defined in: types.ts:57

Axis title font (CSS font shorthand). Default theme.font.

Inherited from ​

AxisConfig.titleFont


type? ​

ts
optional type?: ScaleType;

Defined in: plot.ts:83

MIT licensed. WebGL2 required.