2012-10-05 38 views
9

的線寬我有這個ggplot:增加geom_smooth

ggplot(dt.m, aes(x=pct.on.OAC.cont,y=Number.of.Practices, fill=Age.Group)) + 
    geom_bar(stat="identity",position=position_dodge()) + 
    geom_smooth(aes(x=pct.on.OAC.cont,y=Number.of.Practices, colour=Age.Group), se=F) 

我怎樣才能增加geom_smooth繪製的線條的粗細?

回答

13

不要在size參數做你想要什麼:

+ geom_smooth(aes(x=pct.on.OAC.cont, y=Number.of.Practices, colour=Age.Group), 
       se=F, size=10) 

或者,你可以改變sizelwd,但它是標準的使用size

+1

難道你不會用'尺寸'美學來做這個嗎? – joran

+0

@joran好點。我改變了它。 – csgillespie