Highcharts

Custom tooltips in Highcharts diagrams

家住魔仙堡 提交于 2020-01-24 11:53:48
问题 Is there any way to make completely custom tooltips in Highcharts diagrams? Not just with different data, or with coloured border, but to make it look different (for example, like a bubble with picture in it). 回答1: Try this: .... tooltip: { useHTML: true, formatter: function() { return 'here the html code'; } }, 回答2: Using the options/api you can only configure such things as border properties and colors (see tooltip options). So without editing the source or going outside the api, no it is

Create highchart density with more than 2 groups

爱⌒轻易说出口 提交于 2020-01-24 10:04:25
问题 I tried to create highchart density with more than two groups. I found a way to add them one by one manually but there must be a better way to handle groups. Examples: I would like to create a highchart similar to ggplot chart below without adding them one by one. Is there any way to do so? d f <- data.frame(MEI = c(-2.031, -1.999, -1.945, -1.944, -1.875, -1.873, -1.846, -2.031, -1.999, -1.945, -1.944, -1.875, -1.873, -1.846, -2.031, -1.999, -1.945, -1.944, -1.875, -1.873, -1.846, -2.031, -1

Highcharts annotations not rendering

旧时模样 提交于 2020-01-24 08:44:13
问题 I'm trying to dynamically add annotations to my high charts in React. I'm using the addAnnotation function to add a new annotation whenever a hover event is triggered on my app, but the annotation does not render. I dropped a debugger into my code, and when I call chart.annotations I can see there is currently an array of annotations, but they are not rendering. I even have make a call to the addPlotLine in this function and the plotline is rendered on the chart. My config file looks like

Highcharts. Pie chart. DataLabels formatter

天涯浪子 提交于 2020-01-24 00:51:16
问题 I have a pie chart. And I need to format DataLabels in someway. So I use: dataLabels: { useHTML : true, formatter: function () { if(this.point.id == 'razr') { return '<div><b>' + this.point.y + '</b></div><div style="left: -140px; text-align: center; position: absolute"><b>sum is:<br/>' + this.point.summ + ' </b></div>'; } else return '<b>' + this.point.y + '<b>'; } } And what I got: My problem is here style="left: -140px; . The position is static. I can't find any way to position my sum

highcharts context menu hidden for small charts

霸气de小男生 提交于 2020-01-24 00:47:06
问题 I am migrating a dashboard type screen to highcharts and would like to use the default context menu (for exporting various image formats and printing the chart). The problem is that a lot of these charts are small gauge type charts and the context menu gets hidden when charts get below a certain size, mainly due to the fact that the context menu appears above the button for small charts size. Is there anyway to make the context menu always appear below the button? I know I can limit the

Highcharts series data array

你说的曾经没有我的故事 提交于 2020-01-23 05:54:41
问题 From an ajax call I get the following data back: 18,635,21,177,20,165,22,163,24,162,25,145,19,143,23,139,26,112,27,110,28,104,30,91,29,88,31,68,32,57,36,55,34,53,33,51,35,46,37,44,39,42,43,39,42,39,41,38,38,37,44,36,45,34,48,31,40,31,47,27,49,23,46,21,50,21,52,17,55,17,53,16,51,15,54,12,58,6,57,6,59,4,63,4,56,3,62,2,64,2,100,2,68,1,78,1,60,1,97,1,70,1,65,1,69,1,71,1 Of which every even number should be the key and every odd the value. But I have no idea how to parse it as highcharts data.

Dynamically update subtitle on Highcharts chart?

不羁岁月 提交于 2020-01-23 05:22:32
问题 Is it possible to dynamically update the subtitle of a Highcharts chart? In the docs, I can only see options relating to initial configuration options, not methods to update the chart. In the update I'm doing, I'm also updating the data, and I'd like the highcharts update to be part of a smooth redraw if possible, rather than re-rendering the whole chart. $('#container').highcharts({ subtitle: { text: 'The subtitle' }, ... }); //how to update after initial config? JSFiddle: http://jsfiddle

Disable marker hover in only one marker of highchart

柔情痞子 提交于 2020-01-22 19:46:30
问题 I am trying to convince my highchart to do my bidding and have encountered a problem. What I want to acchieve: I want one of the markers of the graph to disappear. I want the line to go through (and break at) one point, but the point is completely irrelevant and I do not want that point to pop up when hovering over it. My current code looks something like this: $(function () { var chart; $(document).ready(function() { chart = new Highcharts.Chart({ chart: { renderTo: 'container', type: 'line'

How to style two different legends in HighCharts

馋奶兔 提交于 2020-01-22 02:29:06
问题 I have a problem with styling two different symbols of the legend in the HighCharts. Maybe someone know how to write my code correctly, or have some ideas for my problem. I also need to write it without jquery. Thanks and have a good day! I need to style them like in a picture My code now if looking like : const dataX = [49.9, 71.5, 106.4, 129.2, 144.0, 176.0, 135.6, 148.5, 216.4, 194.1, 95.6]; const dataXY = [27.0,9.5,14.5,18.2,21.5,25.2,26.5,23.3,18.3,13.9, 9.6]; let maxX = dataX.reduce(

How to make two charts using highchart show up in the same line side by side using div

怎甘沉沦 提交于 2020-01-21 20:04:15
问题 I want to display two charts in the same line using div. Can you please help? Here is the what I am trying but it shows up in 2 lines. <script src="http://code.highcharts.com/highcharts.js"></script> <script src="http://code.highcharts.com/modules/exporting.js"></script> <div> <div id="container" style="width: 200px; height: 200px; diplay:inline"></div> <div id="container2" style="width: 200px; height: 200px; display:inline"></div> </div> full code in http://jsfiddle.net/nCe36/ 回答1: Just