Overview
Series are used to plot data on XY charts. amCharts 5 provides several series types:- LineSeries - Line and area charts
- ColumnSeries - Column and bar charts
- CandlestickSeries - Candlestick charts
- StepLineSeries - Step line charts
- SmoothedXLineSeries - Smoothed line charts
Base XYSeries Settings
All series share these common settings:X axis series uses.IMPORTANT:
xAxis needs to be set when creating the series. Updating this setting on previously created series object will not work.Y axis series uses.IMPORTANT:
yAxis needs to be set when creating the series. Updating this setting on previously created series object will not work.Input data field for X value.See documentation
Input data field for Y value.See documentation
Input data field for X category.See documentation
Input data field for Y category.See documentation
Input data field for X open value.See documentation
Input data field for Y open value.See documentation
If set to
true series will be stacked to other series that also have this setting set to true.NOTE: for series stack properly, all stacked series must have same number of data items with the same timestamp/category.See documentationWhether to stack negative values from zero (true) or from whatever previous series value is (false).See documentation
Minimal distance between data items in pixels.If data items are closer than this, bullets are turned off to avoid overcrowding.See documentation
Horizontal location of the data point relative to its cell.
0 - beginning, 0.5 - middle, 1 - end.See documentationVertical location of the data point relative to its cell.
0 - beginning, 0.5 - middle, 1 - end.See documentationIf set to
true XYCursor will show closest data item from series even if it is outside currently hovered date axis interval.This setting is relevant only if baseAxis is a date axis.Indicates horizontal position at which to show series’ tooltip at.
Indicates vertical position at which to show series’ tooltip at.
If set to
true, series bullets will be masked by plot area.Whether series’ tooltip should inherit its color from series or its first bullet.
LineSeries
Used to plot line and/or area series.LineSeries Settings
If set to
true the line will connect over “gaps” - categories or time intervals with no data.See documentationIf there are more than
autoGapCount base time intervals (e.g. days) with no data, the line will break and will display gap.See documentationAllows simplifying the line with many points.If set, the series will skip points that are closer than X pixels to each other.With many data points, this allows having smoother, less cluttered lines.
LineSeries Properties
A TemplateList of all line segments in series.
strokes.template can be used to set default settings for all line segments, or to change on existing ones.A TemplateList of all segment fills in series.
fills.template can be used to set default settings for all segment fills, or to change on existing ones.Base XYSeries Properties
A Container that is used to put series’ elements in.
A list of axis ranges that affect the series.See documentation
Base XYSeries Methods
showDataItemTooltip()
Data item to show tooltip for
hideDataItemTooltip()
Data item to hide tooltip for
createLegendMarker()
Optional data item to create marker for
updateLegendMarker()
Optional data item to update marker for
Events
Kicks in when axis starts using different data set, e.g. data of different granularity on DateAxis.