Skip to content

Instantly share code, notes, and snippets.

@mages
Last active December 20, 2015 16:38
Set y limits in googleVis
library(googleVis)
dat <- data.frame(x=LETTERS[1:10],
y=c(0, 4, -2, 2, 4, 3, 8, 15, 10, 4))
area1 <- gvisAreaChart(xvar="x", yvar="y", data=dat,
options=list(vAxes="[{viewWindowMode:'explicit',
viewWindow:{min:0, max:10}}]",
width=500, height=400,
title="y-limits set from 0 to 10"),
chartid="area1ylim")
plot(area1)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment