-1

I want to show the last label as the max value on this pie. In this example I want it to show 825000 as the last label. Is there a way to do this?

    "yAxis": [{
  "lineWidth": 0,
  "min": 0,
  "max": 825000, /* Budget + Contingency */
  tickColor: 'white',
  tickWidth: 4,
  minorTickInterval: 'auto',
  minorTickLength: 3,
  minorTickPosition: 'inside',
  tickPixelInterval: 50,
  tickPosition: '',
  tickLength: 30,
  showLastLabel: false,

https://jsfiddle.net/ahilans/2znc19n6/

1 Answers1

0

You can use yAxis.tickPositioner to get desired labels but it will transform to k for thousand place

yAxis will be

"yAxis": [{
  "lineWidth": 0,
  "min": 0,
  "max": 825000, /* Budget + Contingency */
  tickColor: 'white',
  tickWidth: 4,
  minorTickInterval: 'auto',
  minorTickLength: 3,
  minorTickPosition: 'inside',
  tickPixelInterval: 50,
  tickPosition: '',
  tickLength: 30,
  showLastLabel: true,
  tickPositions: [0, 100000, 200000, 300000,400000,500000,600000,700000 ,825000],

  "labels": {
    "enabled": true,
    distance: 16,
    style: {
      color: '#50a2a7',
      font: '11px Trebuchet MS, Verdana, sans-serif'
    }
  },
  "title": {
    "text": "",
    "useHTML": false,
    "y": 80
  },
  "pane": 0
}],

Fiddle demo

Deep 3015
  • 9,929
  • 5
  • 30
  • 54