When i going to show a line chart or bar chart should have the option to display a label for each dataset.
Example:
new Chart(ctx).Line(data, options);
var options = {
showDatasetLabels : true
}
var data = {
labels : ["January","February","March","April","May","June","July"],
datasets : [
{
label: "Salesman A",
fillColor : "rgba(220,220,220,0.5)",
strokeColor : "rgba(220,220,220,1)",
pointColor : "rgba(220,220,220,1)",
pointStrokeColor : "#fff",
data : [65,59,90,81,56,55,40]
},
{
label: "Salesman B",
fillColor : "rgba(151,187,205,0.5)",
strokeColor : "rgba(151,187,205,1)",
pointColor : "rgba(151,187,205,1)",
pointStrokeColor : "#fff",
data : [28,48,40,19,96,27,100]
}
]
}
It would be a very nice addition, I'm following this too. Thank you.
Yeah I need this right now.
This one line fixes your problem. http://stackoverflow.com/questions/24510278/chart-js-multitooltip-labels
Closing since there is a fix
The above solution is not correct solution. The ask was for label and the proposed solution is to show in label in tooltip. I have a similar problem, In my case my application is projected on big screen and there is no user interaction on chart to generate tooltip. It would be good if we can show label on lines in the chart
I have the same problem, the proposed fix is for TOOLTIP not VALUE LABELs, we are going to show charts on large screen as dashboard, so there is no mouse to hover, how can I show values on each Bar or Column
Most helpful comment
I have the same problem, the proposed fix is for TOOLTIP not VALUE LABELs, we are going to show charts on large screen as dashboard, so there is no mouse to hover, how can I show values on each Bar or Column