I am getting an error when I run the following code in R2.15.0/ggplot2 0.9.1 and R2.14.2/ggplot2 0.9.1. Runs fine in R2.14.1/ggplot2 0.8.9.
require(ggplot2)
timescale <- seq(as.Date("01/01/09","%m/%d/%y"), length.out=12, by=7)
data.all <- data.frame(
id = c(rep('111',12),rep('222',12),rep('333',12)),
week=c(timescale,timescale,timescale),
value=c(rnorm(12,15,3),rnorm(12,30,5),rnorm(12,20,5))
)
p <- ggplot(data.all, aes(x=week, y=value, group=id, colour=id)) +
scale_x_date(format="%m/%d/%y", major="28 days", minor="7 days") + geom_line(size=1.05)
Error in continuous_scale(aesthetics, "date", identity, breaks = breaks, :
unused argument(s) (format = "%m/%d/%y", major = "28 days", minor = "7 days")
Any help would be greatly appreciated. Thanks.