Welcome to OGeek Q&A Community for programmer and developer-Open, Learning and Share
Welcome To Ask or Share your Answers For Others

Categories

0 votes
246 views
in Technique[技术] by (71.8m points)

javascript - Highcharts Custom display of tooltips, based on data series values

I could explain better if you can focus on the image attached here: enter image description here

  1. Can the hover line height be shown only up to the max line height (Please see the image below)

  2. I do not want to show the hover values for first and last week. (I mean on hover of 'week 0', I do not want to show the hover boxes, same as for 'week 7')

  3. Can I set the floor and ceiling for the each series data, Some thing like

    series: [{ name: 'CPM', data: [5,524,4,1,4,1,3,20,3], color: 'rgb(87, 188, 0)' //floor: 5, //ceiling: 524, },{ ....} }]

Is there any such floor/min and max/ceil for the each data set.

Such that the other two series data gets visible in the chart. please refer this fiddle

How to show All Data Series Fiddle jsfiddle.net/4vzEt/21/

enter image description here

See Question&Answers more detail:os

与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
Welcome To Ask or Share your Answers For Others

1 Reply

0 votes
by (71.8m points)
  1. Could you show jsFiddle what is wrong? It's a little not clear for me.
  2. In tooltip.formatter check this.x and return false when tooltip shouldn't be displayed.
  3. Well, you can set that options, but it won't do anything.

Your image is saying something really different than 2) .. to remove that vertical line, just disable tooltip.crosshairs.

To change order of points, you need to use tooltip.formatter - sort points descending and return formatter string.

References:


与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
OGeek|极客中国-欢迎来到极客的世界,一个免费开放的程序员编程交流平台!开放,进步,分享!让技术改变生活,让极客改变未来! Welcome to OGeek Q&A Community for programmer and developer-Open, Learning and Share
Click Here to Ask a Question

...