How can I get a Google Visulization LineChart to display vertical gridlines?
Asked Answered
D

1

7

I am using javascript to display a Google Visulization LineChart in my web application. How can I get it to display vertical gridlines? I've read about using chg to set them, but as far as I know that only applies when making the chart using the query string method. Could you tell me how to get verticle gridlines when initialising the LineChart as follows:

new google.visualization.LineChart(div.get(0)).draw(data, { title: 'Unique visitors - Previous Month', width: div.width(), height: 330, chartArea: {left:50, width:"90%"}, legend: 'none', yAxis: {title: '(thousands)'} });

Danieledaniell answered 21/4, 2011 at 13:54 Comment(0)
B
0

You can use a ScatterChart with a positive lineWidth to emulate a line chart. This component supports vertical grid lines through the hAxis.gridlineColor setting.

Basset answered 19/9, 2011 at 13:33 Comment(1)
the down side is that ScatterChart requires an integer values on axesesRegine

© 2022 - 2024 — McMap. All rights reserved.