Highcharts:以对数刻度显示零值

编程入门 行业动态 更新时间:2024-10-16 02:30:43
本文介绍了Highcharts:以对数刻度显示零值的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧! 问题描述

我使用对数坐标轴在y轴

I am working with logarithmic scale in the y-axis

我知道log(0)不存在,但我需要绘制0值,需要一个对数标度。

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

我在其他答案中读到将零值更改为 null 可以解决问题,它不为我工作。请参阅示例: jsfiddle/QEK3x/15/

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: jsfiddle/QEK3x/15/

提前感谢。

推荐答案

虽然不完美,将零点设置为0.0001,然后将y轴最小值设置为0.0001:

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:

jsfiddle/6LHT8/

yAxis: { min:0.0001, type: 'logarithmic' }, series: [{ data: [100,10,0.0001,0.1,0.01,0.1] }]

此外,此答案可能是nelp: 高图 - 处理和显示的最佳方式在具有对数Y轴的折线图系列中的零(或负)值

更多推荐

Highcharts:以对数刻度显示零值

本文发布于:2023-11-30 02:24:09,感谢您对本站的认可!
本文链接:https://www.elefans.com/category/jswz/34/1648409.html
版权声明:本站内容均来自互联网,仅供演示用,请勿用于商业和其他非法用途。如果侵犯了您的权益请与我们联系,我们将在24小时内删除。
本文标签:对数   刻度   Highcharts

发布评论

评论列表 (有 0 条评论)
草根站长

>www.elefans.com

编程频道|电子爱好者 - 技术资讯及电子产品介绍!