Reputation: 136
I want to keep label in my chart so that it will be descriptive. I have take reference of the chart from https://github.com/ankane/chartkick/issues/155 but doesn't work for me.
My code in the view is as:
= line_chart @event_chart,discrete:true, legend: "bottom",curve: false,
colors: ["#67b55e","#d43766","#729be0"],
:library => {hAxis: {title: "months"}, vAxis: {title: "Y-label"}, title: "no. of events"}
My chart looks like:
Upvotes: 1
Views: 557
Reputation: 136
Through the chartkick documentation I got the answer as:
xtitle: "Time", ytitle: "Population"
adding line of code instead of library.
Upvotes: 1