Skip to examples
Browse chart types
Chart library26 ways to visualize

STATISTICS / CHART GUIDE

Line Chart

A line chart is a statistical chart composed of points and lines in a Cartesian coordinate system, commonly used to represent changes in values over continuous time intervals or ordered categories.

01 / EXPLORE

See it in action.

Switch to Code to copy an example.

Global Average Temperature Anomaly

Monthly Average Temperature Comparison of Four Cities, Custom Colors

Global Renewable Energy Installed Capacity Trend, Custom Palette

Monthly Traffic by Channel (Shared Crosshair and Dense Axis)

About Line Chart

A line chart is a statistical chart composed of points and lines in a Cartesian coordinate system, commonly used to represent changes in values over continuous time intervals or ordered categories. In a line chart, the x-axis is typically used for continuous time intervals or ordered categories, while the y-axis is used for quantitative data — negative values are plotted below the x-axis. Lines connect adjacent data points. Line charts are used to analyze trends of things changing over time or ordered categories. Data-wise, a line chart requires a continuous time field or a categorical field and at least one continuous data field.

02 / CONFIGURE

Make it yours.

The properties available for this chart.

Configuration Options

PropertyTypeRequiredDescription
typestringrequiredValue must be "line".
dataObject[]requiredChart data.
data.timestring | numberrequiredTime series name.
data.valuenumberrequiredData value.
data.groupstringoptionalGroup name.
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.
style.lineWidthnumberoptionalValue must be greater than 0.
GPT-Vis · An AntV project · MIT licensed