The Chart axes provide a value scale for the plotted data series.
Depending on the series types you use, the Chart delivers:
- A set of Category and Value axes (in Categorical and Radar series).
- A set of X and Y axes (in Scatter and Polar series).
- No axes (in Pie and Funnel series).
Category axes are declared through the ChartCategoryAxisItem configuration components and placed in a ChartCategoryAxis collection. For more information on the available data-binding options, refer to the section on binding categories.
The following example demonstrates how to configure the Value and Category axes of the category Chart.
- Automatic selection for the duration of the category time slots (minutes, hours, days, and so on)
- Aggregated series values for each time slot
- Label formatting that matches the time slot duration
To disable the Category axis features for displaying time series, set the axis mode to
When the Category Chart is set to display time series, the Category axis divides into time slots. To set the time scale for these slots, define a "base unit", which can be hours, days, weeks, and so on. By default, the base unit matches the smallest time interval between the source dates. This approach ensures that all data points that are present in the original series will be displayed as they are.
Setting the base unit to
"fit" limits the total number of categories either to the set
maxDateGroups value or, otherwise, to the default
maxDateGroups value of
When the Category Chart is set to display time series, it processes the data points for each time slot and produces a new point by using an aggregate function.
By default, the
aggregate function returns the maximum value of the value fields. If the category contains only one point,
aggregate returns the point without modification. Other aggregates, such as
sum, produce their own value even if the category contains only one data point.
Normally, each date interval gets its own label. Labels may overlap and become illegible in densely populated charts. To work around this issue, set an upper limit to the number of labels for display by using the
You can save space and rotate the labels at a fixed or at an optimal (
"auto") angle by using the
To display the exact start and end date of the axis range, set the
rangeLabels.visible setting to
The range labels support the same settings as the axis labels. If an option is not set, it will default to the value set for the regular labels. For example
rangeLabels.color defaults to the value of
Toggle the range labels in the example below to see how they differ from the regular axis labels:
The following example demonstrates how to configure the X and Y axes of the Scatter Chart.
The Scatter Chart provides option for:
When the Scatter Chart is set to display time series, its axis divides into time slots. To set the time scale for these slots, define a "base unit", which can be hours, days, weeks, and so on.
baseUnitsetting for the Scatter Charts affects only the axis labels. This behavior contrasts the settings of the Categorical Chart axes that are used by the Chart to compute time series aggregates.
You can also apply settings to all Chart axes, regardless of their kind, by using the ChartAxisDefaults component.
The ChartAxisDefaults component supports the following child components:
The following example demonstrates how to set the default axis color and label font.
The Kendo UI for Vue Chart supports multiple axis. This helps you leverage the best charting performance and visualize data on any number of axis to provide solid business reports for your users.
The example illustrates a weather report and includes information for the: max and min temperatures, wind speed and rainfall in mm. Note that each of them has a unique name which is set through the name property. You can also populate the axisCrossingValue array to specify the alignment of the value axes.