1.绘制散点图
p <- ggplot(mtcars,aes(mpg,hp,colour=factor(cyl))) + geom_point()
p
图1
2.去除背景色
p + theme_bw()
图2
3.去除网格线
p + theme_bw() +
theme(panel.grid=element_blank())
图3
1.绘制散点图
p <- ggplot(mtcars,aes(mpg,hp,colour=factor(cyl))) + geom_point()
p
2.去除背景色
p + theme_bw()
3.去除网格线
p + theme_bw() +
theme(panel.grid=element_blank())