Frage

Does Chartkick allow users to label the x/y axies?

     Sample Code:
     <%= line_chart Product.group("purchased").maximum(:price) %>
War es hilfreich?

Lösung

Yes, with Google Charts, use:

<%= line_chart Product.group("purchased").maximum(:price), {library: {hAxis: {title: "X"}, vAxis: {title: "Y"}}} %>

Lizenziert unter: CC-BY-SA mit Zuschreibung
Nicht verbunden mit StackOverflow
scroll top