Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Highcharts - How can I remove starting and ending padding from area chart

Fiddle - http://jsfiddle.net/vKLPP/

I want to remove the white space on both sides (see the red lines).

I tried various options like minpadding, margin etc but none of them seem to work.

startOnTick: true,
minpadding:0
like image 472
Sumedh Avatar asked Nov 02 '22 22:11

Sumedh


1 Answers

for this no need to go with categories or the datetime type of x-axis just change the data

in this format

data: [,[x1,y1],[x2,y2],[x3,y3],[x4,y4],[x5,y5]]

ex:

 data: [[1750,106], [1800,107], [1850,111], [1900,133], [1950,221], [1999,767], [2050,1766]]

updated your js fiddle please check http://jsfiddle.net/vKLPP/1/

hope this will be useful

like image 136
Strikers Avatar answered Nov 09 '22 10:11

Strikers