Miguel Flores
Miguel Flores

Reputation: 147

Combine xAxis Highcharts

I have a chart from highcharts.js my problem is that for example... I have a line chart with 5 values (5 points) and my chart shows the xAxis like this from value 1 to value 2: 0, 0.25, 0.5, 0.75, 1, what I want to do is to remove 0.25, 0.5, 0.75 and keep only 0 and 1, then 1 and 2, etc... something like this:

enter image description here

How can I do that?

Here is a CodePen demo

Upvotes: 0

Views: 32

Answers (1)

Barbara Laird
Barbara Laird

Reputation: 12717

You can control that with tickInterval:

    xAxis: {

        labels: {
            rotation: -33,
        },
      tickInterval:1
    },

http://codepen.io/bhlaird/pen/WoGmNd

http://api.highcharts.com/highcharts/xAxis.tickInterval

Upvotes: 1

Related Questions