Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- plot.wrap <- function(df, x, y, filename, ...) {
- g <- ggplot(df, aes_string(x=x, y=y)) +
- geom_point(colour="limegreen", size=3) + theme_light() + ...
- ggsave(plot=g, filename=filename)
- d <- data.frame(A=1:10, B=2:11, C=3:12)
- plot.wrap(d, "A", "B", filename="AB.pdf") # A-B plot
- plot.wrap(d, "A", "C", filename="AC.pdf") # A-C plot
- plot.wrap(d, "B", "C", filename="BC.pdf") # B-C plot
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement