[英] Controlling both the major and minor grid lines on the y axis
library(ggplot2)
x <- c(1:100)
y <- c(1:100)
ch1 <- qplot(x, y)
ch2 <- ch1 +
theme(panel.grid.minor = element_line(colour = "white", size = 0.5)) +
scale_y_continuous(minor_breaks = seq(0, 100, 5))
ch2
我正在用ggplot制作一张图表,可以控制y轴的小网格线.