Skip to examples
Browse chart types
Chart library26 ways to visualize

STATISTICS / CHART GUIDE

Bar Chart

A bar chart is a statistical chart that uses horizontal rectangular bars to compare numerical values across different categories.

01 / EXPLORE

See it in action.

Switch to Code to copy an example.

2024 Global Programming Language Popularity

Five Industries Quarterly Revenue Comparison, Custom Colors

Regional Product Line Sales, Custom Palette

About Bar Chart

A bar chart is a statistical chart that uses horizontal rectangular bars to compare numerical values across different categories. Unlike column charts, bar chart bars are arranged from left to right rather than from bottom to top. A bar chart also requires a categorical variable and a numerical variable. In a bar chart, each entity of the categorical variable is represented as a horizontal rectangular bar, and the numerical value determines the length of the bar.

02 / CONFIGURE

Make it yours.

The properties available for this chart.

Configuration Options

PropertyTypeRequiredDescription
typestringrequiredValue must be "bar".
dataObject[]requiredChart data.
data.categorystring | numberrequiredCategory name.
data.valuenumberrequiredCategory value.
data.groupstringoptionalGroup name. Required when grouping or stacking is enabled.
groupbooleanoptionalWhether to enable grouping.
stackbooleanoptionalWhether to enable stacking.
titlestringoptionalChart title.
axisXTitlestringoptionalX-axis title.
axisYTitlestringoptionalY-axis title.
themeBuiltinThemeName | ThemeSpecoptionalBuilt-in theme name or custom theme object; default is "default". See Documentation → Custom Themes.
styleObjectoptionalChart style.
style.backgroundColorstringoptionalMust be a valid color value.
style.palettestring[]optionalMust be an array of valid color values.
GPT-Vis · An AntV project · MIT licensed