How to add single value to yaxis label? Just like this 80 value:
如何为yaxis标签添加单个值?就像这个80值:
1) For the line use markings, for example add this to your chart options:
1)对于线路使用标记,例如将其添加到图表选项中:
grid: { markings: [ { xaxis: { from: 0, to: 2000 }, yaxis: { from: 80, to: 80 }, color: "black" }, ... ] ... }
Change the from and to values according to your needs and min/max values.
from
to
min/max
根据您的需要和最小/最大值更改from和to值。
2) For the value on the axis you have to add it manually like this (see the example):
2)对于轴上的值,您必须像这样手动添加它(参见示例):
var o = plot.pointOffset({ x: plot.getAxes().xaxis.min, y: 80.0}); $(plot.getPlaceholder()).append("80");