Skip to content

BarSeriesType API

Extended documentation for the BarSeriesType interface with detailed information on the module's properties and available APIs.

Demos

Import

import { BarSeriesType } from '@mui/x-charts'

Properties

Type:'bar'


Optional

Type:string


Optional

Data associated to each bar.

Type:(number | null)[]


Optional

The key used to retrieve data from the dataset.

Type:string


Optional

The scope to apply when the series is highlighted.

Type:Partial<HighlightScope>


Optional

Type:SeriesId


Optional

The label to display on the tooltip or the legend. It can be a string or a function.

Type:string | ((location: 'tooltip' | 'legend') => string)


Optional

Layout of the bars. All bar should have the same layout.

Type:'horizontal' | 'vertical'

Default:'vertical'


Optional

The key that identifies the stacking group.
Series with the same stack property will be stacked together.

Type:string


Optional

Defines how stacked series handle negative values.

Type:StackOffsetType

Default:'diverging'


Optional

The order in which series' of the same group are stacked together.

Type:StackOrderType

Default:'none'


Optional

Formatter used to render values in tooltip or other data display.

Type:SeriesValueFormatter<TValue>


Optional

The id of the x-axis used to render the series.

Type:string


Optional

The id of the x-axis used to render the series.

Type:string


Optional

The id of the y-axis used to render the series.

Type:string


Optional

The id of the y-axis used to render the series.

Type:string