Hide/show rows whith checkbox in line chart

1,039 views
Skip to first unread message

Schabagh

unread,
Dec 25, 2014, 5:44:06 AM12/25/14
to google-visua...@googlegroups.com
Hi,

how can I Hide/Show the lines in a line chart via checkboxes. I found the following example "http://jsfiddle.net/gTxkN/1/". This works grate, but the other line colors are chnged if I hide a line, which is irritating. How can I fix it? Is there a better way for Hide/Show vis checkboxes?

Thanks

Daniel LaLiberte

unread,
Dec 26, 2014, 11:10:22 AM12/26/14
to google-visua...@googlegroups.com
If you want to keep the same colors, you'll have to assign them yourself for now.  I modified that jsfiddle to show how it can be done: http://jsfiddle.net/dlaliberte/a3cgLkq6/

--
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.
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

Schabagh

unread,
Dec 26, 2014, 11:53:11 AM12/26/14
to google-visua...@googlegroups.com
Hi Daniel,

thanks for your reply.
You have defined here three colors. which are static. The number of curves are different for me and the colors can't be defined as static colors. For this reason the series colors must be determined bevorhand.

Thanks

manoj kumar janagam

unread,
Sep 22, 2017, 6:14:40 AM9/22/17
to Google Visualization API
how to do this in dual axis. As the target axis is changing when the series number changes.
Reply all
Reply to author
Forward
0 new messages