我试图从 geom_smooth 中删除回归线,只保留置信区间。我尝试过size = 0
,size = NULL
和size = NA
, 但没有任何效果。有没有人知道的简单解决方法?
baseball <- ddply(x, .(id), transform, bat.avg = h/ab)
hank <- subset(baseball, id == 'aaronha01')
ggplot(hank, aes(x = year, y = bat.avg)) +
geom_line(size = 1.2, color = '#336699') +
geom_smooth(fill = '#bf3030', size = NA) +
labs(x = '', y = '')