Format currency in tooltip #200

jtlindsey opened this Issue Aug 20, 2015 · 3 comments


None yet

3 participants



I'm using a column chart with rails and managed to get currency working on the y axis, but not in the tool tip.
screen shot 2015-08-19 at 8 00 20 pm

Here is my original code in helper.rb

  def networth_data
      {name: "Assets", data: {"NetWorth": Account.assets(current_user)}}, 
      {name: "Liabilities", data: {"NetWorth": Account.liabilities(current_user)}}

And in view

<%= column_chart networth_data, colors: ["green", "#FF0000"], library: {pointSize: 0, vAxis:  {format: "currency"}, backgroundColor: "#FFF", height: 265} %>

screen shot 2015-08-19 at 7 58 08 pm

Im not sure what to change to get the tooltip displaying the currency instead of raw number. Is there a way to change this?


I have the same problem


I ended up turning the tooltip off. See example.

<%= column_chart networth_data, colors: ["green", "#FF0000"], library: {pointSize: 0, vAxis:  {format: "currency"}, legend: { position: 'none'}, backgroundColor: "#FFF", height: 265} %>
@ankane ankane added the enhancement label Jan 7, 2017
ankane commented Jan 7, 2017

It'd be great to have a prefix option for this (and a suffix one for things like percentages).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment