CategoryAxis
configurationThe category axis configuration options.
categoryAxis
ArraySpecifies the discretebaseUnitStepvalues when eitherbaseUnitis set to "fit" orbaseUnitStepis set to "auto".
The default configuration is as follows:
minutes: [1, 2, 5, 15, 30]hours: [1, 2, 3, 6, 12]days: [1, 2, 3]weeks: [1, 2]months: [1, 2, 3, 6]years: [1, 2, 3, 5, 10, 25, 50]
Each setting can be overriden individually.
categoryAxis.axisCrossingValue
Object | Date | ArrayCategory index at which the first value axis crosses this axis. (Only for object)
Category indicies at which the value axes cross the category axis. (Only for array)
**Note:**Specify an index greater than or equal to the number of categories to denote the far end of the axis.
categoryAxis.baseUnit
StringThe base time interval for the axis. The default baseUnit is determined automatically from the minimum difference between subsequent categories. Available options:
- minutes
- hours
- days
- weeks
- months
- years
*fit
SettingbaseUnitto "fit" will set such base unit andbaseUnitStep that the total number of categories does not exceedmaxDateGroups.
Series data is aggregated for the specified base unit by using the series.aggregatefunction.
Sets the step (interval) between categories in base units. Specifiying "auto" will set the step to such value that the total number of categories does not exceedmaxDateGroups.
This option is ignored ifbaseUnitis set to "fit".
Default: 1
Array of category names.
categoryAxis.color
StringColor to apply to all axis elements. Any valid CSS color string will work here, including hex and rgb. Individual color settings for line and labels take priority.
categoryAxis.crosshair
ObjectThe crosshair configuration options.
categoryAxis.field
StringThe data field containing the category name.
categoryAxis.justified
BooleanPositions categories and series points on major ticks. This removes the empty space before and after the series.
This option is ignored if either bar or column series are plotted on the axis.
Default: false
categoryAxis.labels
ObjectConfigures the axis labels.
categoryAxis.line
ObjectConfigures the axis line. This will also effect major and minor ticks, but not gridlines.
Configures the major grid lines. These are the lines that are an extension of the major ticks through the body of the chart.
categoryAxis.majorTicks
ObjectThe major ticks of the axis.
categoryAxis.max
ObjectThe last date displayed on the axis. By default, the minimum date is the same as the last category. This is often used in combination with theminandroundToBaseUnitconfiguration options to set up a fixed date range.
Specifies the maximum number of groups (categories) to produce when eitherbaseUnitis set to "fit" orbaseUnitStepis set to "auto".
Default: 10
The maximum number of ticks and labels to display. Applicabable for date category axis.
This option is ignored in all other cases.
categoryAxis.min
ObjectThe first date displayed on the axis. By default, the minimum date is the same as the first category. This is often used in combination with themaxandroundToBaseUnitconfiguration options to set up a fixed date range.
Configures the minor grid lines. These are the lines that are an extension of the minor ticks through the body of the chart.
Note that minor grid lines are not visible by default, therefore none of these settings will take effect with the minor grid lines visibility being set totrue.
categoryAxis.minorTicks
ObjectThe minor ticks of the axis.
categoryAxis.name
StringThe unique axis name.
Default: "primary"
categoryAxis.notes
ObjectThe category axis notes configuration.
The plot bands of the category axis.
categoryAxis.reverse
BooleanReverses the axis direction - categories are listed from right to left and from top to bottom.
Default: false
categoryAxis.roundToBaseUnit
BooleanBy default, the first and last dates will be rounded off to the nearest base unit. Specifyingfalsefor this option will disable this behavior.
This option is most useful in combination with explicitminandmaxdates.
It will be ignored if either bar or column series are plotted on the axis.
Default: true
categoryAxis.title
ObjectThe title of the category axis.
categoryAxis.type
StringThe axis type.
"category"
Discrete category axis.
"date"
Specialized axis for displaying chronological data.
Default: "category"
categoryAxis.visible
BooleanThe visibility of the axis.
Default: false
Specifies the week start day whenbaseUnitis set to "weeks". Use the kendo.days constants to specify the day by name.
- kendo.days.Sunday (0)
- kendo.days.Monday (1)
- kendo.days.Tuesday (2)
- kendo.days.Wednesday (3)
- kendo.days.Thursday (4)
- kendo.days.Friday (5)
- kendo.days.Saturday (6)
Default: kendo.days.Sunday