search for: scale_shap

Displaying 16 results from an estimated 16 matches for "scale_shap".

Did you mean: scale_shape
2009 Mar 20
1
ggplot2: specifying legend titles
I am trying to specify a legend title to be other than the variable name, but I find that the legend splits because scale_shape() takes effect but scale_colour() does not. Can someone spot my error? Here's some toy code that produces the problem on my system (R2.8.1, windows, today's CRAN package updates): library(ggplot2) a <- sample(letters[1:5],100,replace=T) b <- rnorm(100) c <- rnorm(100) qpl...
2023 May 31
1
scale_colour_viridis en ggplot2
...a principal radica en el tipo de escala (continua o categórica) y en la intensidad de los colores utilizados en cada función. Debes seleccionar la opción que mejor se ajuste a tus datos y a tus objetivos de representación visual. Ahora para imprimir en blanco y negro, creo lo mejor sería pensar en `scale_shape` https://ggplot2.tidyverse.org/reference/scale_shape.html Saludos Mauricio Mardones I. Researcher Instituto de Fomento Pesquero PhD Student Antarctic and SubAntarctic Science Universidad de Magallanes, Chile +56 9 66209279 +34 611709287 > On May 31, 2023, at 10:52 PM, Javier Gómez Gonzalez...
2013 Mar 07
3
ggpliot2: reordering of factors in facets facet.grid(). Reordering of factor on x-axis no problem.
...+ sdv)) + geom_point(position = position_dodge(width = 0.25), size = 3) + geom_line(position = position_dodge(width = 0.25)) + geom_errorbar(width = 0.3, position = position_dodge(width = 0.25), size = 0.3) + facet_wrap(~Grouping, ncol = 2) + theme(strip.background = element_blank()) + scale_shape(solid = FALSE)+ theme_bw() + ylab(expression(paste("my measured stuff"))) + xlab("factor3") + theme(legend.position="none")+ labs(shape = "factor1", group = "factor1", linetype = "factor1") # What I find really scary is that wh...
2008 Jun 10
1
Sweave, ggplot2 and two-page figures
...=factor(bos2), shape=factor(bos2), size=factor(cumARscore), position="jitter", main="Days to BOS by Days to First AR", xlab="Days of Follow-up", ylab="Daysto First AR") + geom_smooth(aes(group=bos2), method='rlm', fill=alpha("grey", 0.4)) + scale_shape(solid=FALSE,name="BOS\nFalse = 0\nTrue = 1") + scale_size_identity() + facet_grid(bos2 ~ ., margins=TRUE) +scale_colour_manual(name="BOS\nFalse = 0\nTrue = 1", values=c("blue", "purple"))) grid.gedit(gPath("strip","label"),gp=gpar(font...
2008 Nov 17
1
ggplot2: using more than 6 symbols
I'm trying to plot multiple lines using different colours/symbols to distinguish them. If I try to plot more than 6 lines, I get an error: > ggplot( dat, aes(x=time,y=value,group=variable,shape=variable) ) + geom_line() Error: scale_shape can deal with a maximum of 6 discrete values, but you have 9. See ?scale_manual for a possible alternative I find this slightly confusing, as there are ~25 symbols listed for use. (I'm using ggplot2 0.7, on OSX, R 2.7.2) Ideally, I'd like to use a combination of colours and symbols...
2009 Jul 23
1
tweak a bit the legend wiht ggplot2
...et. Here is my code to get the graph: pdf("isotherm.pdf",width=7,height=6) #windows(width=7,height=6) ads.graph<-ggplot(Adsorp.DATA,aes(relative.p,ads.vol,shape=type ,color=adsorbent))+ geom_point(size=I(3)) + labs(x=expression(p/p[0]),y=N[2]~adsorbed~volume~(cc/g)) + scale_shape(name="Adsorption\nProcedure" ,solid=F ,breaks=c("A","D") ,labels=c("Adsorp.","Desorp.") ) + scale_colour_hue(name="Adsorbent") + scale_x_continuous(limits=c(0,1),minor_breaks = seq(0,1,0.1)) + scale_y_continuous(limits=c(0,...
2008 Sep 10
1
ggplot2: edge outlines on points
...- ggplot(data=DF, aes(x=X, y=Y)) + geom_point(aes(colour=TRT),size=4) + scale_colour_grey(end=0.8) + theme_bw pedge <- ggplot(data=DF, aes(x=X, y=Y)) + geom_point(aes(colour=TRT),size=4) + scale_colour_grey(end=0.8) + scale_shape(solid=FALSE) + theme_bw However, I can't figure out the correct syntax, if this is even the right way to go about it. Any suggestions as to the best approach to achieve filled points with an edge outline would be greatly appreciated. ----------------------------------------...
2008 Nov 04
1
ggplot2 scatterplot matrix
...t;SC 2007/04", "SC 2007/06", "SC 2007/08"), class = "data.frame")) plotmatrix(d[,3:6]) I would like to either have a colour or more preferably a shape to correspond to Site this is what I have tried (along with many other combinations) plotmatrix(nmds.bug[,3:6])+scale_shape(nmds.bug, shape=Site, pch=1:12) thanks -- Stephen Sefick Research Scientist Southeastern Natural Sciences Academy Let's not spend our time and resources thinking about things that are so little or so large that all they really do for us is puff us up and make us feel like gods. We are mam...
2023 May 31
2
scale_colour_viridis en ggplot2
Hola a todos: Alguién me podría explicar cuales son las diferencias entre las diferentes escalas de viridis en ggplot2, es decir en qué se diferencian scale-colour_viridis_d de scale_colour_viridis_c, scale_colour_viridis_b. Y cual es la diferencia entre scale-fiil-viridis_d de scale-fill_viridis_c y de scale_fill_viridis-b. He estado buscando la diferencia en internet y no he encontrado nada al
2009 Apr 10
1
png with ggplot on windows xp
...ns(); colnames(myData) <- c("Effect","Power","N") p <- ggplot(data=myData,aes(x=Effect,y=N)) p <- p+geom_point(aes(shape=factor(Power))) + geom_line(aes(group=factor(Power))) p <- p+scale_x_continuous(expression("Effect Size as "*R^2)) p <- p + scale_shape(name="Power") ggsave(file = "myoutput1.png") ggsave(file = "myoutput1.pdf") > sessionInfo() R version 2.8.1 (2008-12-22) i386-pc-mingw32 locale: LC_COLLATE=English_United States.1252;LC_CTYPE=English_United States.1252;LC_MONETARY=English_United States.1252;LC...
2011 Jul 10
2
grey colored lines and overwriting labels i qqplot2
....789695.n4.nabble.com/file/n3657119/color_graph_2.gif And now I would like to add lines fitting accordingly with the grey scale. Where can I find out the names of the grey tones? 4.) I would like to add different shapes. However, when I type >p+ geom_point(aes(shape = factor(TREATMENT))) + scale_shape(solid = FALSE) I get this error message: Error: scale_shape_discrete can deal with a maximum of 6 discrete values, but you have 7. See ?scale_manual for a possible alternative. I did not find anything useful looking at the scale_manual pages. Any tips on how to add another symbol? 5. ) Fin...
2013 Sep 18
1
ggplot2: changing strip text in facet_grid and a legend text problem
...N")))+ xlab("Week") + geom_line(stat="summary", fun.y = "mean", mapping=aes(linetype=organism, group=organism))+ #must add jitter if using this geom_point(stat="summary", fun.y = "mean", size=2, mapping=aes(shape=organism))+ scale_shape(solid = FALSE) + #must be unfilled geom_hline(yintercept=0, linetype=3) + #draws dotted line at 0 theme(strip.text.x = element_text(size = 16, colour="black", family="serif", angle=00)) + theme(strip.text.y = element_text(size = 16, colour="black", family="...
2012 Mar 02
0
ggplot2 0.9.0
...he width of the other lines (thanks to suggestion by Di Cook), and the line type can now be set. Notched box plots are now supported by setting `notch = TRUE` (thanks to Winston Chang for the patch). * `ggsave` can work with cm and mm `units` (Thanks to patch from Jean-Olivier Irisson) * `scale_shape` finally returns an error when you try and use it with a continuous variable * `stat_contour` no longer errors if all breaks outside z range (fixes #195). * `geom_text` remove rows with missing values with warning (fixes #191) * New generic function `autoplot` for the creation of complete plo...
2012 Mar 02
0
ggplot2 0.9.0
...he width of the other lines (thanks to suggestion by Di Cook), and the line type can now be set. Notched box plots are now supported by setting `notch = TRUE` (thanks to Winston Chang for the patch). * `ggsave` can work with cm and mm `units` (Thanks to patch from Jean-Olivier Irisson) * `scale_shape` finally returns an error when you try and use it with a continuous variable * `stat_contour` no longer errors if all breaks outside z range (fixes #195). * `geom_text` remove rows with missing values with warning (fixes #191) * New generic function `autoplot` for the creation of complete plo...
2013 Mar 06
6
Ggplot2: Moving legend, change fill and removal of space between plots when using grid.arrange() possible use of facet_grid?
Hi, # For publications, I am not allowed to repeat the axes. I have tried to remove the axes using: # yaxt="n", but it did not work. I have not understood how to do this in ggplot2. Can you help me? # I also do not want loads of space between the graphs (see below script with Dummy Data). # If I could make it look like the examples on the (nice) examples page: #
2009 Jun 01
1
installing sn package
...ot object name (note the missing y=.. in aes()) to plot different y-values against the same set of x-values. p.b4.generic.wg <-   ggplot(subset(b4.all.medians, ncpus==8, TRUE), aes(x=wg)) +   geom_line(aes(linetype=graph, group=interaction(graph,nwrk,ncpus))) +   geom_point(aes(shape=nwrk)) +   scale_shape(name="# of workers") + scale_linetype(name="Workload") +   xlab("Work division") + ylab("N/A") Now, p.b4.stealspins <- p.b4.generic.wg + aes(y=v.stealspins / v.realtime) +   ylab("Steal rate") draws the correct graph EXCEPT that the y-axis la...