Razor Storm
Razor Storm

Reputation: 12326

Adding labels for graphael bar charts?

I am using graphael to draw barcharts for my data, and couldn't figure out how to give the bar charts a label.

var r = Raphael(element);
r.hbarchart(10, 20, 500, 220, barData, {colors:colors, type:'square'}).hover(fin, fout);

Upvotes: 3

Views: 4026

Answers (1)

Jonathan Julian
Jonathan Julian

Reputation: 12264

Call label on your chart object.

  var barChart = r.g.barchart(0, 0, 200, 200, [3,2,1]);
  barChart.label(['a','b','c']);

Upvotes: 4

Related Questions