question on defaults for geom_smooth

10 views
Skip to first unread message

David Faden

unread,
Feb 6, 2009, 4:34:02 PM2/6/09
to ggp...@googlegroups.com
Hi,

What's the default method for doing a smooth in geom_smooth? I guess
loess, but what are the parameters used? Do the confidence bands come
from predict.loess? (Does anyone know of a good source for learning
more about how the estimated standard errors are computed?) Thanks
(and sorry if I've missed something obvious)!

David

hadley wickham

unread,
Feb 7, 2009, 9:49:07 AM2/7/09
to David Faden, ggp...@googlegroups.com
Hi David,

There are two default methods for geom_smooth:

* less than 1000 points, loess is used
* more than 1000 points, mgcv::gam(y ~ s(x, bs = "cs")) is used

Yes, the confidence bands come from predict.loess or predict.gam, and
you'll probably need to read the cited papers to figure out exactly
how they are calculated.

Hadley
--
http://had.co.nz/
Reply all
Reply to author
Forward
0 new messages