Hi I'm trying to do a GAM analysis and have the following codes entered into R (density is = sample number, alive are the successes)
density<-as.real(density) y<-cbind(alive,density-alive) library(mgcv) m1<-gam(y~s(density),binomial) at which point I get the following error message Error in smooth.construct.tp.smooth.spec(object, dk$data, dk$knots) : A term has fewer unique covariate combinations than specified maximum degrees of freedom What am I doing wrong? Please help! Thanks! ______________________________________________ [email protected] mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide http://www.R-project.org/posting-guide.html and provide commented, minimal, self-contained, reproducible code.

