简体   繁体   中英

Removing the confidence interval on ggplot2 on plot

I have a plot and I am trying to remove the confidence interval(the gray cast on the smooth line)for each on my line but it's not working. I used the code below:

ggplot(data, aes(x=, y=)) + geom_smooth(aes(color="KHRC"),se = FALSE, span = 0.3)+
  geom_smooth(data=GO1,aes(color="GO1"))+
  geom_smooth(data=GO2,aes(color="GO2"))+
  geom_smooth(data=GO4,aes(color="GO4"))+
  geom_smooth(data=GO3,aes(color="GO3"))+
  geom_smooth(data=GO6,aes(color="GO6"))+
  scale_x_datetime(limits = c(ymd_hms("2016-11-05 09:00:00"), ymd_hms("2016-11-07 00:00:00")))+
  labs(color="ID")+
  ggtitle("x vs y ")

I need help with what code to use to remove the confidence interval.Also, I see no difference when I change the span, suggestions on that too will be great.Thank you for your help in advance.

ggplot(data, aes(x=, y=)) + geom_smooth(aes(color="KHRC"),se = FALSE, span = 0.3)+
  geom_smooth(data=GO1,aes(color="GO1"),se = FALSE,span = 0.3)+
  geom_smooth(data=GO2,aes(color="GO2"),se = FALSE,span = 0.3)+
  geom_smooth(data=GO4,aes(color="GO4"),se = FALSE,span = 0.3)+
  geom_smooth(data=GO3,aes(color="GO3"),se = FALSE,span = 0.3)+
  geom_smooth(data=GO6,aes(color="GO6"),se = FALSE,span = 0.3)+
  scale_x_datetime(limits = c(ymd_hms("2016-11-05 09:00:00"), ymd_hms("2016-11-07 00:00:00")))+
  labs(color="ID")+
  ggtitle("x vs y ")

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM