Reputation: 8113
I can't find in the Chart API the way to remove any axis from a bar chart. For instance:
cht=bvg
chs=410x150
chd=s:StackOverflow
How to remove the gray x and y axis?
Upvotes: 3
Views: 2669
Reputation: 5060
(based on Alexander Farber's answer, but with some minor improvements)
You can add
chxt=x,y
chxs=0,,0,0,_|1,,0,0,_
Explanation:
chxt=x,y
Which axis to show. Even though axis x and y are shown as default, we still need to specify those to be able to apply styling with chxs.
chxs=0,,0,0,_|1,,0,0,_
Styling for the two axis, separated by pipe. Separated by comma, we have:
0
= first (x), 1
= second (y)0
will hide the labels, and thus we don't need to set empty labels with chxl0
is fine._
will hide bothMore info at https://developers.google.com/chart/image/docs/chart_params#axis_label_styles
Upvotes: 2
Reputation: 23058
Please try appending
&chxt=x,y&chxs=0,000000,10,0,,000000|1,000000,10,0,,000000&chxl=0:||1:|
Upvotes: 4
Reputation: 8113
All I found is this trick: cover them with a white line and it works
cht=bvg
chs=410x150
chd=s:StackOverflow
chm=r,FFFFFF,0,-0.01,0.01,1
R,FFFFFF,0,-0.01,0.01,1
...but any "cleaner" way?
Upvotes: 3