Mohan Ram
Mohan Ram

Reputation: 8463

Bar chart using raphaël

I like to bring a chart as shown

alt text

By using rapheal. Its very tough for me to learn it. show me some live example with code to draw verticalbar graph.

My data values

x-axis {1,2,3,4,5} This is an id of question y-axis {10,20,30,40,7} This represent number of visits of question

I need bar graph with x,y values in plot and label for each axis and for graph

Upvotes: 0

Views: 1639

Answers (1)

Ege Özcan
Ege Özcan

Reputation: 14269

The most basic implementation would be:

var r = Raphael("holder"),
    data = [[10], [105], [30]];

r.g.barchart(0, 0, width, height, data);

Then you can manipulate it with raphael.js.

Note. g.raphael can be found here: http://g.raphaeljs.com/

Upvotes: 1

Related Questions