noamross / gams-in-r-course

Generalized Additive Models in R: A Free Interactive Course
https://noamross.github.io/gams-in-r-course
Other
243 stars 69 forks source link

spatial x,y components cover 99.6% deviance #41

Open leandrom84 opened 2 years ago

leandrom84 commented 2 years ago

dear Noam, im dealing with data of nest sites (nido=0/1) and wanted to explore the spatial component. When running the spatial GAM i got the result that Rsq is 1. Im not sure if im running something. At the momment my response variable (nido=0/1) is set as factor to able to use the binomail-logit function. any toughts? thanks so much, your post/site is amazing!!

mod4

Family: binomial Link function: logit

Formula: nido ~ te(x, y)

Estimated degrees of freedom: 7.63 total = 8.63

UBRE score: -0.3558566

summary(mod4)

Family: binomial Link function: logit

Formula: nido ~ te(x, y)

Parametric coefficients: Estimate Std. Error z value Pr(>|z|) (Intercept) 26.03 97.69 0.266 0.79

Approximate significance of smooth terms: edf Ref.df Chi.sq p-value te(x,y) 7.626 7.94 0.267 1

R-sq.(adj) = 1 Deviance explained = 99.6% UBRE = -0.35586 Scale est. = 1 n = 27