Unwanted spacing on combo chart

21 views
Skip to first unread message

Dan

unread,
May 31, 2016, 7:14:24 AM5/31/16
to Google Visualization API
Hi
I have some unwanted space on the left of the Area chart in my combo chart.
Why doesn't it start against the Y axis like the line chart does?
https://jsfiddle.net/burntsausage/sxz419gw/

Thanks

Daniel LaLiberte

unread,
May 31, 2016, 9:38:49 AM5/31/16
to Google Visualization API
Dan,

It is actually the 'steppedArea' series that is causing the extra space around each domain value, unlike the 'area' series that behaves more like 'line' series.   If you change 'steppedArea' to 'line', you'll see that the extra space disappears.  The area and line series wouldn't know where to draw in that extra space around the values because there is no next value to connect to, whereas the steppedArea series makes its transitions half-way between domain values, at least when the domain values are discrete, as is the case with your string values for the months.  But if you change the domain values to numbers instead, then the steppedArea series behaves more like line series. 

Hope that helps explain what you are seeing.

--
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 https://groups.google.com/group/google-visualization-api.
To view this discussion on the web visit https://groups.google.com/d/msgid/google-visualization-api/b24f6798-1132-4f30-9221-e8d6add8c5da%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.



--

Dan

unread,
May 31, 2016, 9:59:03 AM5/31/16
to Google Visualization API
Thank you!
I'm not quite sure why I had the months as strings now...!
Thanks again for you help :)

Reply all
Reply to author
Forward
0 new messages