4

I am working with logarithmic scale in the y-axis

I know that log(0) doesn't exist but I need to draw 0 values, and I need a log scale.

I read in other answers that changing the zero values to null solve the problem, but it is not working for me. See the example: http://jsfiddle.net/QEK3x/15/

Thank you in advance.

David Torres
  • 1,767
  • 1
  • 16
  • 19

1 Answers1

-2

Although not perfect, the best I came up with was to set the zero point to 0.0001 and then set the y-axis min to 0.0001:

http://jsfiddle.net/6LHT8/

yAxis: {        
    min:0.0001,
    type: 'logarithmic'
},

series: [{
    data: [100,10,0.0001,0.1,0.01,0.1]
}]

Also, this answer may nelp: Highcharts - best way to handle and display zero (or negative) values in a line chart series with logarithmic Y axis

Community
  • 1
  • 1
SteveP
  • 18,840
  • 9
  • 47
  • 60
  • Actually I tried that. But 1e-20 instead of 0.0001, which is very high for my case. But unfortunately that was not accepted because the users are going to see that is not 0, and being exactly 0 or not is important in this case. – David Torres Oct 18 '13 at 14:02
  • Refer to the link I posted. I think it will fix that for you. – SteveP Oct 18 '13 at 15:01