[R] ggplot - controlling point size
Felipe Carrillo
mazatlanmexico at yahoo.com
Tue Jan 25 18:44:50 CET 2011
try this:
qplot(x, y, data=df, colour=factor(type), size=I(1)) + geom_smooth()
Felipe D. Carrillo
Supervisory Fishery Biologist
Department of the Interior
US Fish & Wildlife Service
California, USA
http://www.fws.gov/redbluff/rbdd_jsmp.aspx
----- Original Message ----
> From: Gene Leynes <gleynes+r at gmail.com>
> To: r-help at r-project.org
> Sent: Tue, January 25, 2011 9:28:20 AM
> Subject: [R] ggplot - controlling point size
>
> Can anyone illuminate the following for me?
> How can I get rid of the blue line in the key in the second plot?
>
> ## Create a simple data frame
> df=data.frame(x=1:1000, y=2*1:1000+rnorm(1000,sd=1000),
> type=sample(letters[1:2],1000, replace=TRUE))
>
> ## Very nice! Almost what I want
> qplot(x, y, data=df, colour=factor(type)) + geom_smooth()
>
> ## Make a nicer plot, with smaller points
> ## but why does that add the little blue line with a 1?
> qplot(x, y, data=df, colour=factor(type), size=1) + geom_smooth()
>
> [[alternative HTML version deleted]]
>
> ______________________________________________
> R-help at r-project.org mailing list
> https://stat.ethz.ch/mailman/listinfo/r-help
> PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
> and provide commented, minimal, self-contained, reproducible code.
>
More information about the R-help
mailing list