Google Charts Column chart - How can I show a tooltip when the value is so small the column height < 1 pixel?

113 views
Skip to first unread message

arka....@gmail.com

unread,
Nov 19, 2015, 5:28:35 AM11/19/15
to Google Visualization API

I am displaying some visualizations using Google Charts.

There is great variance in the data so some large numbers co-exist with small ones. In the case of aColumn Chart this results in a scaling whereby some of the small values probably compute to less than one pixel of height and are thus invisible.

As a result there is no area to hover above, so I cannot show a tooltip.

Is anyone aware of a way to show a tooltip in this situation?

How about the white space above columns? Is there a way to include that as part of the hover region? I cannot find info about this in the Google Charts documentation so it is unlikely, but maybe someone is aware of a way...


Daniel LaLiberte

unread,
Nov 19, 2015, 8:47:30 AM11/19/15
to Google Visualization API
If you set the baselineColor for the vAxis to 'transparent' then you can see even a 0 value, and hovering over it works.  The ColumnChart should now show at least one pixel of height, but it would be hidden by the baseline.  

Another thing to consider is to use log scale, if you have a large number of small values and relatively few large values.  If you need to represent 0 values, there is a scaleType: 'mirrorLog' option instead which can show negative and 0 values.

--
You received this message because you are subscribed to the Google Groups "Google Visualization API" group.
To unsubscribe from this group and stop receiving emails from it, send an email to google-visualizati...@googlegroups.com.
To post to this group, send email to google-visua...@googlegroups.com.
Visit this group at http://groups.google.com/group/google-visualization-api.
To view this discussion on the web visit https://groups.google.com/d/msgid/google-visualization-api/4a927c66-7a7a-4ccb-9b56-d28c3270b2c6%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.



--
dlaliberte@Google.com   5CC, Cambridge MA
daniel.laliberte@GMail.com 9 Juniper Ridge Road, Acton MA
Reply all
Reply to author
Forward
0 new messages