Reputation: 592
I am working on an app, which requires me to highlight few points on History Chart (I am using Highchart's Highstocks).
this question seems to be answering my question, but my point is this - I cannot add marker & plotoptions only to this graph as in backend I am using python class which renders the data for all history chart. So I prefer this modification to be done in frontend.
One more Question which answers similar requirements is
Comparing the Marker Points to average
In my application this comparison also is done with respect to the array of elements against list of values. (I can render an array which has same number of elements as of data points, that are to be compared).
While drawing the graph I am getting properly, required points are in required colors. My question goes here
When I hover out of the changed color markers, the color of marker turns to default color. (I may have lost, but need a way to figure out) (1) How can I retain the changed color ? Or (2) Is there a better way to assign colors to marker points rendered the array of values to be compared as stated above ?
I am new to highcharts, any help in this regard is welcome...
Upvotes: 0
Views: 262
Reputation: 108507
If I understand you correctly, you want to highlight one or more points outside of the initial plot configuration? The easiest way would be to update the specific points after the plot is initially drawn.
var chart = $('#container').highcharts()
chart.series[0].points[4].update({color: 'red'});
Here's an example jsFiddle.
Upvotes: 0