Box
Map
A newer version of this page is available. Switch to the current version.

jQuery Chart - argumentAxis.tickInterval

Specifies the interval between major ticks.

Type:

Number

|

Object

|

String

Default Value: undefined
Accepted Values: 'day' | 'hour' | 'millisecond' | 'minute' | 'month' | 'quarter' | 'second' | 'week' | 'year'

Major ticks divide an axis into segments, thus improving the viewer's perception of visualized data. Major ticks are generated automatically, unless the tickInterval property is set.

If the axis displays numbers, assign a number to this property. If the axis displays date-time values, assign one of the accepted string values or an object to this property. The object should contain one or several fields described in this section, for example:

jQuery
JavaScript
$(function() {
    $("#chartContainer").dxChart({
        // ...
        argumentAxis: {
            // ...
            tickInterval: { days: 5 }
        }
    });
});
Angular
HTML
TypeScript
<dx-chart ... >
    <dxo-argument-axis ... >
        <dxo-tick-interval [days]="5"></dxo-tick-interval>
    </dxo-argument-axis>
</dx-chart>
import { DxChartModule } from "devextreme-angular";
// ...
export class AppComponent {
    // ...
}
@NgModule({
    imports: [
        // ...
        DxChartModule
    ],
    // ...
})
Vue
App.vue
<template>
    <DxChart ... >
        <DxArgumentAxis>
            <DxTickInterval :days="5" />
        </DxArgumentAxis>
    </DxChart>
</template>

<script>
import DxChart, {
    DxArgumentAxis,
    DxTickInterval
} from 'devextreme-vue/chart';

export default {
    components: {
        DxChart,
        DxArgumentAxis,
        DxTickInterval
    }
}
</script>
React
App.js
import React from 'react';

import Chart, {
    ArgumentAxis,
    TickInterval
} from 'devextreme-react/chart';

class App extends React.Component {
    render() {
        return (
            <Chart ... >
                <ArgumentAxis>
                    <TickInterval days={5} />
                </ArgumentAxis>
            </Chart>
        );
    }
}

export default App;     

When you use an axis of the "logarithmic" type, ticks are generated on a base of powers. For example, assuming that the logarithm base is 10 and the tick interval is 1, ticks are generated at 10-2, 10-1, 100, 101, 102, 103, etc. If the tick interval becomes 2, ticks are generated at 10-1, 101, 103, etc.

See Also
  • argumentAxis.tick - configures the appearance of major ticks.
  • argumentAxis.minorTickInterval - specifies the interval between minor ticks.

days

Specifies the time interval measured in days. Accepts integer values. Available only for an axis/scale that displays date-time values.

Type:

Number

hours

Specifies the time interval measured in hours. Accepts integer values. Available only for an axis/scale that displays date-time values.

Type:

Number

milliseconds

Specifies the time interval measured in milliseconds. Accepts integer values. Available only for an axis/scale that displays date-time values.

Type:

Number

minutes

Specifies the time interval measured in minutes. Accepts integer values. Available only for an axis/scale that displays date-time values.

Type:

Number

months

Specifies the time interval measured in months. Accepts integer values. Available only for an axis/scale that displays date-time values.

Type:

Number

quarters

Specifies the time interval measured in quarters. Accepts integer values. Available only for an axis/scale that displays date-time values.

Type:

Number

seconds

Specifies the time interval measured in seconds. Accepts integer values. Available only for an axis/scale that displays date-time values.

Type:

Number

weeks

Specifies the time interval measured in weeks. Accepts integer values. Available only for an axis/scale that displays date-time values.

Type:

Number

years

Specifies the time interval measured in years. Accepts integer values. Available only for an axis/scale that displays date-time values.

Type:

Number