I see an error message when trying to build a gam object in R:
Error in 1:object$nsdf : argument of length 0
I use the main command:
plot(myGamObject)
This error is not specific to any data that I use, as it also appears at the end of the procedure:
example(gam)
For completeness, here is an example code:
library(ISLR) library(gam) gam7 <- gam(wage~lo(year, span = 2) + s(age, 4) + maritl + education + health_ins + health + jobclass, data = Wage) plot(gam7)
and here is my system:
sysname release version nodename "Windows" ">= 8 x64" "build 9200" "MEANMACHINE4" machine login user effective_user "x86-64" "Julian" "Julian" "Julian"
source share