We're getting very close to another release of ggplot2. I think it's
now at the point where it would be useful for more people to start
trying out the development version. The easiest way to get it is:
install.packages("devtools")
library(devtools)
dev_mode() # to avoid clobbering existing install
install_github("scales")
install_github("ggplot2")
Please read the news file for an extensive list of changes:
news(Version == "0.9.0", package = "ggplot2")
If you do discover problems, please sign up for the ggplot-dev mailing
list and discuss them there. That will help keep discussions about
the released version separate from the development version.
You can follow progress on bugs etc at
https://github.com/hadley/ggplot2/issues?milestone=1
Thanks!
Hadley
--
Assistant Professor / Dobelman Family Junior Chair
Department of Statistics / Rice University
http://had.co.nz/
ggplot2 0.9 now passes R CMD check, so unless I discover any show
stopper bugs I'll be releasing it to CRAN in the next couple of days.
Again, it would be greatly appreciated if you tried it out with a few
of your plots - I'm trying to get better at writing automated tests,
but there's still a long way to go.
install.packages("devtools")
library(devtools)
dev_mode() # to avoid clobbering existing install
install_github("scales")
install_github("ggplot2")
You can see all the changes (and there are a lot!) by running:
news(Version == "0.9.0", package = "ggplot2")
Hadley
A minor thing, I can't get the news line to work for some reason,
news(Version == "0.9.0", package = "ggplot2")
Error in charToDate(x) :
character string is not in a standard unambiguous format
Also, have you considered keeping a ggplotGrob function? (recent post
in ggplot2-dev)
Thanks,
baptiste
> sessionInfo()
R version 2.14.1 RC (2011-12-20 r57945)
Platform: i386-apple-darwin9.8.0/i386 (32-bit)
locale:
[1] en_GB.UTF-8/en_GB.UTF-8/en_GB.UTF-8/C/en_GB.UTF-8/en_GB.UTF-8
attached base packages:
[1] stats graphics grDevices utils datasets methods base
other attached packages:
[1] ggplot2_0.9.0
loaded via a namespace (and not attached):
[1] colorspace_1.1-0 dichromat_1.2-3 digest_0.5.1 grid_2.14.1
[5] MASS_7.3-16 memoise_0.1 munsell_0.3 plyr_1.6
[9] proto_0.3-9.2 RColorBrewer_1.0-2 reshape2_1.2 scales_0.1.0
[13] stringr_0.6 tools_2.14.1
> --
> You received this message because you are subscribed to the ggplot2 mailing list.
> Please provide a reproducible example: http://gist.github.com/270442
>
> To post: email ggp...@googlegroups.com
> To unsubscribe: email ggplot2+u...@googlegroups.com
> More options: http://groups.google.com/group/ggplot2
Just fixed.
> Also, have you considered keeping a ggplotGrob function? (recent post
> in ggplot2-dev)
Just added.
Out of curiosity, is there a specific reason not to use alpha as a
setting in the layer instead?
ggplot(df, aes(xmin = x, xmax = x + 1, ymin = y, ymax = y + 2)) +
geom_rect(aes(fill = grp), alpha=0.5) +
scale_fill_manual(values=c('red','blue'))
b.
> To unsubscribe: email ggplot2+unsub...@googlegroups.com
> More options: http://groups.google.com/group/ggplot2
--
You received this message because you are subscribed to the ggplot2 mailing list.
Please provide a reproducible example: http://gist.github.com/270442
To post: email ggp...@googlegroups.com
To unsubscribe: email ggplot2+unsub...@googlegroups.com
More options: http://groups.google.com/group/ggplot2
gridExtra should work fine, but you probably won't be able to use
ggExtra (and I've removed it from r-forge). Which functions
specifically have you been using?
baptiste
>> To unsubscribe: email ggplot2+u...@googlegroups.com
>> More options: http://groups.google.com/group/ggplot2
>
> --
> You received this message because you are subscribed to the ggplot2 mailing
> list.
> Please provide a reproducible example: http://gist.github.com/270442
>
> To post: email ggp...@googlegroups.com
>> To unsubscribe: email ggplot2+unsub...@googlegroups.com
>> More options: http://groups.google.com/group/ggplot2
>
> --
> You received this message because you are subscribed to the ggplot2 mailing
> list.
> Please provide a reproducible example: http://gist.github.com/270442
>
> To post: email ggp...@googlegroups.com
> To unsubscribe: email ggplot2+unsub...@googlegroups.com
> More options: http://groups.google.com/group/ggplot2
>
>
--
You received this message because you are subscribed to the ggplot2 mailing list.
Please provide a reproducible example: http://gist.github.com/270442
To post: email ggp...@googlegroups.com
I posted a minimal example a few days ago: https://gist.github.com/1513290
HTH,
baptiste
>>> To unsubscribe: email ggplot2+u...@googlegroups.com
>>> More options: http://groups.google.com/group/ggplot2
>>
>> --
>> You received this message because you are subscribed to the ggplot2
>> mailing
>> list.
>> Please provide a reproducible example: http://gist.github.com/270442
>>
>> To post: email ggp...@googlegroups.com
>> To unsubscribe: email ggplot2+u...@googlegroups.com
>> More options: http://groups.google.com/group/ggplot2
>>
>>
>
> --
> You received this message because you are subscribed to the ggplot2 mailing
> list.
> Please provide a reproducible example: http://gist.github.com/270442
>
> To post: email ggp...@googlegroups.com
FYI you should never use ::: and rarely use ::. Just load scales
explicitly with library(scales)
For the other issue, I've created a bug report at
https://github.com/hadley/ggplot2/issues/335
Thanks,
Evan Misshula
Grad Student, PhD program in Criminal Justice CUNY John Jay
> --
> You received this message because you are subscribed to the ggplot2 mailing list.
> Please provide a reproducible example: http://gist.github.com/270442
>
> To post: email ggp...@googlegroups.com
> To unsubscribe: email ggplot2+u...@googlegroups.com
> More options: http://groups.google.com/group/ggplot2
--
Evan Misshula
Doctoral Student (Criminal Justice)
CUNY John Jay
"Let us reform our schools, and we shall find little reform needed in
our prisons."
John Ruskin, Unto This Last, essay 2 (1862)
English critic, essayist, & reformer (1819 - 1900)
"Instruction does much, but encouragement does everything." Johann
Wolfgang Von Goethe
www.snrg-nyc.org
>>> To unsubscribe: email ggplot2+unsub...@googlegroups.com
>>> More options: http://groups.google.com/group/ggplot2
>>
>> --
>> You received this message because you are subscribed to the ggplot2
>> mailing
>> list.
>> Please provide a reproducible example: http://gist.github.com/270442
>>
>> To post: email ggp...@googlegroups.com
>> To unsubscribe: email ggplot2+unsub...@googlegroups.com
>> More options: http://groups.google.com/group/ggplot2
>>
>>
>
> --
> You received this message because you are subscribed to the ggplot2 mailing
> list.
> Please provide a reproducible example: http://gist.github.com/270442
>
> To post: email ggp...@googlegroups.com
Just start a fresh R session.
sessionInfo()
R version 2.14.1 RC (2011-12-20 r57945)
Platform: i386-apple-darwin9.8.0/i386 (32-bit)
locale:
[1] en_GB.UTF-8/en_GB.UTF-8/en_GB.UTF-8/C/en_GB.UTF-8/en_GB.UTF-8
attached base packages:
[1] grid stats graphics grDevices utils datasets
methods base
other attached packages:
[1] ggplot2_0.9.0 gridExtra_0.7.1 proto_0.3-9.2 devtools_0.5.1
loaded via a namespace (and not attached):
[1] colorspace_1.1-0 dichromat_1.2-3 digest_0.5.1 MASS_7.3-16
[5] memoise_0.1 munsell_0.3 plyr_1.6 RColorBrewer_1.0-2
[9] RCurl_1.8-0 reshape2_1.2 scales_0.1.0 stringr_0.6
[13] tools_2.14.1
baptiste
I don't get the same error message you reported in 0.9.0:
> g <- tableGrob(head(iris[1:3,]))
> d <- qplot(1,1, geom="blank")
> d + annotate("custom", x=1, y=1, grob=g)
Error: No geom called custom
See ?annotate in 0.9.0. The first argument of annotate() is geom, so
it's expecting the quoted name of an existing geom. Since there is no
geom_custom(), an error is thrown. What were you trying to annotate?
It's entirely possible that there is another way to do it.
Since this problem arose in 0.8.9, it wasn't caused by the changes in
the development version, although it clearly persists there.
Dennis
PS: You really should start a new thread for these things rather than
changing the direction of an existing one.
> sessionInfo()
R version 2.14.1 (2011-12-22)
Platform: x86_64-pc-mingw32/x64 (64-bit)
locale:
[1] LC_COLLATE=English_United States.1252
[2] LC_CTYPE=English_United States.1252
[3] LC_MONETARY=English_United States.1252
[4] LC_NUMERIC=C
[5] LC_TIME=English_United States.1252
attached base packages:
[1] grid stats graphics grDevices utils datasets methods
[8] base
other attached packages:
[1] gridExtra_0.8.5 ggplot2_0.9.0 devtools_0.5.1
loaded via a namespace (and not attached):
[1] colorspace_1.1-0 dichromat_1.2-3 digest_0.5.1 MASS_7.3-16
[5] memoise_0.1 munsell_0.3 plyr_1.6 proto_0.3-9.2
[9] RColorBrewer_1.0-5 RCurl_1.8-0.1 reshape2_1.2 scales_0.1.0
[13] stringr_0.6 tools_2.14.1
>>>> To unsubscribe: email ggplot2+unsub...@googlegroups.com
>>>> More options: http://groups.google.com/group/ggplot2
>>>
>>> --
>>> You received this message because you are subscribed to the ggplot2
>>> mailing
>>> list.
>>> Please provide a reproducible example: http://gist.github.com/270442
>>>
>>> To post: email ggp...@googlegroups.com
>>> To unsubscribe: email ggplot2+unsub...@googlegroups.com
>>> More options: http://groups.google.com/group/ggplot2
>>>
>>>
>>
>> --
>> You received this message because you are subscribed to the ggplot2
>> mailing
>> list.
>> Please provide a reproducible example: http://gist.github.com/270442
>>
>> To post: email ggp...@googlegroups.com
>> To unsubscribe: email ggplot2+unsub...@googlegroups.com
>> More options: http://groups.google.com/group/ggplot2
>>
>>
>
>
> --
> You received this message because you are subscribed to the ggplot2 mailing
> list.
> Please provide a reproducible example: http://gist.github.com/270442
>
> To post: email ggp...@googlegroups.com
> To unsubscribe: email ggplot2+unsub...@googlegroups.com
> More options: http://groups.google.com/group/ggplot2
>
>
> --
> You received this message because you are subscribed to the ggplot2 mailing
> list.
> Please provide a reproducible example: http://gist.github.com/270442
>
> To post: email ggp...@googlegroups.com
> To unsubscribe: email ggplot2+unsub...@googlegroups.com
> More options: http://groups.google.com/group/ggplot2
--
You received this message because you are subscribed to the ggplot2 mailing list.
Please provide a reproducible example: http://gist.github.com/270442
To post: email ggp...@googlegroups.com
> library('plyr')
> library('reshape2')
> dsmall <- diamonds[sample(nrow(diamonds), 100), ]
> dsmall <- rename(dsmall, c("cut" = "Cut"))
> ggplot(dsmall, aes(carat, price)) +
+ geom_point() +
+ annotate("custom", x=0, y=11000, table=ddply(dsmall,"Cut", summarise,
+ Avg_price = mean(price)),
+ gp=gpar(cex=1), just=c("left","bottom"), show.rownames=F,
+ gpar.coretext = gpar(fontsize=9,
+ col="lightblue",fontface="bold.italic")) +
+ geom_text(aes(x=0.4, y=16000, label="Table of Means"),
colour="red")
Error in grobWidth(grob) : argument "grob" is missing, with no default
Maybe you could get away with something like
annotate(..., grob = tableGrob(ddply(dsmall, "Cut", ...)
but Baptiste is the expert on matters involving gridExtra. All I'm
suggesting is to break up the code a bit so that it's easier to see
where things might go wrong.
HTH,
Dennis
>>>>> To unsubscribe: email ggplot2+u...@googlegroups.com
>>>>> More options: http://groups.google.com/group/ggplot2
>>>>
>>>> --
>>>> You received this message because you are subscribed to the ggplot2
>>>> mailing
>>>> list.
>>>> Please provide a reproducible example: http://gist.github.com/270442
>>>>
>>>> To post: email ggp...@googlegroups.com
>>>> To unsubscribe: email ggplot2+u...@googlegroups.com
>>>> More options: http://groups.google.com/group/ggplot2
>>>>
>>>>
>>>
>>> --
>>> You received this message because you are subscribed to the ggplot2
>>> mailing
>>> list.
>>> Please provide a reproducible example: http://gist.github.com/270442
>>>
>>> To post: email ggp...@googlegroups.com
>>> To unsubscribe: email ggplot2+u...@googlegroups.com
>>> More options: http://groups.google.com/group/ggplot2
>>>
>>>
>>
>>
>> --
>> You received this message because you are subscribed to the ggplot2
>> mailing
>> list.
>> Please provide a reproducible example: http://gist.github.com/270442
>>
>> To post: email ggp...@googlegroups.com
>> To unsubscribe: email ggplot2+u...@googlegroups.com
>> More options: http://groups.google.com/group/ggplot2
>>
>>
>> --
>> You received this message because you are subscribed to the ggplot2
>> mailing
>> list.
>> Please provide a reproducible example: http://gist.github.com/270442
>>
>> To post: email ggp...@googlegroups.com
>> To unsubscribe: email ggplot2+u...@googlegroups.com
>> More options: http://groups.google.com/group/ggplot2
>
> --
> You received this message because you are subscribed to the ggplot2 mailing
> list.
> Please provide a reproducible example: http://gist.github.com/270442
>
> To post: email ggp...@googlegroups.com
baptiste
>>>>>> To unsubscribe: email ggplot2+unsub...@googlegroups.com
>>>>>> More options: http://groups.google.com/group/ggplot2
>>>>>
>>>>> --
>>>>> You received this message because you are subscribed to the ggplot2
>>>>> mailing
>>>>> list.
>>>>> Please provide a reproducible example: http://gist.github.com/270442
>>>>>
>>>>> To post: email ggp...@googlegroups.com
>>>>> To unsubscribe: email ggplot2+unsub...@googlegroups.com
>>>>> More options: http://groups.google.com/group/ggplot2
>>>>>
>>>>>
>>>>
>>>> --
>>>> You received this message because you are subscribed to the ggplot2
>>>> mailing
>>>> list.
>>>> Please provide a reproducible example: http://gist.github.com/270442
>>>>
>>>> To post: email ggp...@googlegroups.com
>>>> To unsubscribe: email ggplot2+unsub...@googlegroups.com
>>>> More options: http://groups.google.com/group/ggplot2
>>>>
>>>>
>>>
>>>
>>> --
>>> You received this message because you are subscribed to the ggplot2
>>> mailing
>>> list.
>>> Please provide a reproducible example: http://gist.github.com/270442
>>>
>>> To post: email ggp...@googlegroups.com
>>> To unsubscribe: email ggplot2+unsub...@googlegroups.com
>>> More options: http://groups.google.com/group/ggplot2
>>>
>>>
>>> --
>>> You received this message because you are subscribed to the ggplot2
>>> mailing
>>> list.
>>> Please provide a reproducible example: http://gist.github.com/270442
>>>
>>> To post: email ggp...@googlegroups.com
>>> To unsubscribe: email ggplot2+unsub...@googlegroups.com
>>> More options: http://groups.google.com/group/ggplot2
>>
>> --
>> You received this message because you are subscribed to the ggplot2 mailing
>> list.
>> Please provide a reproducible example: http://gist.github.com/270442
>>
>> To post: email ggp...@googlegroups.com
>> To unsubscribe: email ggplot2+unsub...@googlegroups.com
>> More options: http://groups.google.com/group/ggplot2
>>
>>
--
You received this message because you are subscribed to the ggplot2 mailing list.
Please provide a reproducible example: http://gist.github.com/270442
To post: email ggp...@googlegroups.com
--
Sorry but I've lost track of what we're talking about: an example of
using annotation_custom, the code itself, an example intended for
gridExtra, or ggplot2? I'm assuming the first two; I'll try to submit
a pull request with the file I attached earlier as soon as I
understand what that involves.
baptiste
Yup, that's right. Feel free to email the ggplot-dev mailing list if
you need a hand.
Hadley
qplot(rnorm(100),rnorm(100),color="#cc000044")
plot(rnorm(100),rnorm(100),bg="#cc000044",pch=21)