I am new to charts but I've been trying to add a tooltip to a chart for last couple hours and I just kept failing all I want is do add a tooltip on points hover with text - point_number + "rating"
$(function () {
var plot = $.plot($("#placeholder"),[
{ data: [[0,30],[1,20],[2,0],[3,50],[4,80],[5,16],[6,10],[7,100],[8,80],[9,100]], color: '#8edf00'}
], {
series: {
lines: { show: true, fill: true, fillColor: '#daff93' },
points: { show: true}
},
grid: {
color: 'transparent',
margin: 10
},
xaxis: {
min:1,
color: '#777',
font: { color: '#777777', family: 'sans-serif', size: 11}
},
yaxis: {
max: 100,
min: 0,
color: '#777',
font: { color: '#777777', family: 'sans-serif', size: 11}
}
});
});
The problem is, I want to keep the chart as simple as possible, but all the charts examples with tooltip extremely messy all around the net, so i haven't really find any good tutorial to do that.