Skip to content
Prev 318897 / 398502 Next

Ggplot2: Moving legend, change fill and removal of space between plots when using grid.arrange() possible use of facet_grid?

For the simplist of the issues use  scale_shape(solid = FALSE) to get hollow points
 Using your data (below) this seems to work
p1  <-  ggplot(SummAB, aes(factor3, mean,
          colour = factor1, group = factor1,shape = factor1)) + 
        scale_y_continuous(guide_legend(legend.position=c(4 ,6))) +
       scale_shape(solid = FALSE) + guides(colour = guide_legend(title.position = "right")) +
       geom_point(aes(shape=factor(factor1)), color="black", fill="white",
        position = "dodge", width = 0.3, size=3) +
       geom_line(aes(linetype=factor1), color = "black", size = 0.5) +
       geom_errorbar(aes(ymin = mean - sdv , ymax = mean + sdv), width = 0.3,
                position = "dodge", color = "black", size=0.3) +
      theme_bw() +
       ylab(expression(paste("my measured stuff"))) +
       xlab("factor3") + ggtitle("") +
      labs(color = "factor1", shape = "factor1", group = "factor1",
       linetype = "factor1")
p1

John Kane
Kingston ON Canada
____________________________________________________________
Receive Notifications of Incoming Messages
Easily monitor multiple email accounts & access them with a click.
Visit http://www.inbox.com/notifier and check it out!

Thread (13 messages)

Anna Zakrisson Ggplot2: Moving legend, change fill and removal of space between plots when using grid.arrange() possible use of facet_grid? Mar 6 stephen sefick Ggplot2: Moving legend, change fill and removal of space between plots when using grid.arrange() possible use of facet_grid? Mar 6 ONKELINX, Thierry Ggplot2: Moving legend, change fill and removal of space between plots when using grid.arrange() possible use of facet_grid? Mar 6 John Kane Ggplot2: Moving legend, change fill and removal of space between plots when using grid.arrange() possible use of facet_grid? Mar 6 John Kane Ggplot2: Moving legend, change fill and removal of space between plots when using grid.arrange() possible use of facet_grid? Mar 6 John Kane Ggplot2: Moving legend, change fill and removal of space between plots when using grid.arrange() possible use of facet_grid? Mar 6 Anna Zakrisson Ggplot2: Moving legend, change fill and removal of space between plots when using grid.arrange() possible use of facet_grid? Mar 6 Anna Zakrisson Ggplot2: Moving legend, change fill and removal of space between plots when using grid.arrange() possible use of facet_grid? Mar 6 Anna Zakrisson Ggplot2: Moving legend, change fill and removal of space between plots when using grid.arrange() possible use of facet_grid? Mar 6 Anna Zakrisson Ggplot2: Moving legend, change fill and removal of space between plots when using grid.arrange() possible use of facet_grid? Mar 7 Anna Zakrisson Ggplot2: Moving legend, change fill and removal of space between plots when using grid.arrange() possible use of facet_grid? Mar 7 John Kane Ggplot2: Moving legend, change fill and removal of space between plots when using grid.arrange() possible use of facet_grid? Mar 7 Anna Zakrisson Ggplot2: Moving legend, change fill and removal of space between plots when using grid.arrange() possible use of facet_grid? Mar 7