similar to: Sum of the deviance explained by each term in a gam model does not equal to the deviance explained by the full model.

Displaying 20 results from an estimated 9000 matches similar to: "Sum of the deviance explained by each term in a gam model does not equal to the deviance explained by the full model."

2007 Oct 08
2
variance explained by each term in a GAM
Hello fellow R's, I do apologize if this is a basic question. I'm doing some GAMs using the mgcv package, and I am wondering what is the most appropriate way to determine how much of the variability in the dependent variable is explained by each term in the model. The information provided by summary.gam() relates to the significance of each term (F, p-value) and to the
2012 Jan 13
1
deviance and variance - GAM models
Hi all, This is pretty basic but I am not an expert and I couldn't find anything in the forum or my statistics book about it. I was reading a paper and the authors were using both "explained deviance" and "explained variance" as synonyms. They were describing a GAM regression. Is that right? I performed an analysis in R to take a look to the output of GAM regression and I
2012 Jan 16
1
GAM without intercept reports a huge deviance
Hi all, I constructed a GAM model with a linear term and two smooth terms, all of them statistically significant but the intercept was not significant. The adjusted r2 of this model is 0.572 and the deviance 65.3. I decided to run the model again without intercept, so I used in R the following instruction: regression= gam(dependent~ +linear_independent +s(smooth_independent_1)
2009 May 27
1
Deviance explined in GAMM, library mgcv
Dear R-users, To obtain the percentage of deviance explained when fitting a gam model using the mgcv library is straightforward: summary(object.gam) $dev.expl or alternatively, using the deviance (deviance(object.gam)) of the null and the fitted models, and then using 1 minus the quotient of deviances. However, when a gamm (generalizad aditive mixed model) is fitted, the
2011 Jun 16
0
proportion explained by each term in a GAM
Dear list, I have read several posts on this topic. I would use the same methodology as proposed by Simon Wood in this post: http://r.789695.n4.nabble.com/variance-explained-by-each-term-in-a-GAM-td836513.html My first question is: Does anyone know a scientific source (paper, book,...) that explains or uses this methodology. I have read several articles, particularly in the field of ecology,
2011 Mar 11
0
variance explained by each term in a GAM
Picking up an ancient thread (from Oct 2007), I have a somewhat more complex problem than given in Simon Wood's example below. My full model has more than two smooths as well as factor variables as in this simplified example: b <- gam(y~fv1+s(x1)+s(x2)+s(x3)) Judging from Simon's example, my guess is to fit reduced models to get components of deviance as follows: b1 <-
2009 Jul 12
1
variance explained by each predictor in GAM
Hi, I am using mgcv:gam and have developed a model with 5 smoothed predictors and one factor. gam1 <- gam(log.sp~ s(Spr.precip,bs="ts") + s(Win.precip,bs="ts") + s( Spr.Tmin,bs="ts") + s(P.sum.Tmin,bs="ts") + s( Win.Tmax,bs="ts") +factor(site),data=dat3) The total deviance explained = 70.4%. I would like to extract the variance explained
2009 Nov 10
1
Calculating the percentage of explained deviance in lmer
Dear all, I am trying to calculate some measure of the amount of variability in the response variable that is explained by a model fitted in lmer m1<-lmer(response-var ~ Condition+(1|Site/Area/Transect),family="binomial") . I've seen from the literature that the precentage of explained deviance is a common measure. How can I calculate it? Thanks a lot for your help, I hope this
2005 Jul 08
1
explained deviance in multinom
Hi: I'm working with multinomial models with library nnet, and I'm trying to get the explained deviance (pseudo R^2) of my models. I am assuming that: pseudo R^2= 1 - dev(model) / dev (null) where dev(model) is the deviance for the fitted model and dev(null) is the deviance for the null model (with the intercept only). library(nnet) full.model<- multinom(cbind(factor1,
2005 Sep 20
1
Estimate predictor contribution in GAM models
hi, i'm using gam() function from package mgcv. if G is my gam object, then >SG=summary(G) Formula: y ~ +s(x0, k = 5) + s(x1) + s(x2, k = 3) Parametric coefficients: Estimate std. err. t ratio Pr(>|t|) (Intercept) 3.462e+07 1.965e+05 176.2 < 2.22e-16 Approximate significance of smooth terms: edf chi.sq p-value s(x0)
2009 May 05
1
A question about using “by” in GAM model fitting of interaction between smooth terms and factor
I am a little bit confusing about the following help message on how to fit a GAM model with interaction between factor and smooth terms from http://rss.acs.unt.edu/Rdoc/library/mgcv/html/gam.models.html: ?Sometimes models of the form: E(y)=b0+f(x)z need to be estimated (where f is a smooth function, as usual.) The appropriate formula is: y~z+s(x,by=z) - the by argument ensures that the smooth
2010 Jan 26
1
AIC for comparing GLM(M) with (GAM(M)
Hello I'm analyzing a dichotomous dependent variable (dv) with more than 100 measurements (within-subjects variable: hours24) per subject and more than 100 subjects. The high number of measurements allows me to model more complex temporal trends. I would like to compare different models using GLM, GLMM, GAM and GAMM, basically do demonstrate the added value of GAMs/GAMMs relative to
2009 Apr 28
2
Why there is no p-value from likelihood ratio test using anova in GAM model fitting?
Hello, everybody, There is the first time for me to post a question, because I really cannot find answer from books, websites or my colleagues. Thank you in advance for your help! I am running likelihood ratio test to find if the simpler model is not significant from more complicated model. However, when I run LRT to compare them, the test did not return F value and p-value for me. What's the
2018 Mar 04
2
Random effect in GAM (mgcv)
Dear R users, I am using the *mgcv package* to model the ratio of hectares of damaged culture by wild boar in french departments according to some environmental covariates. I used a _Beta distribution_ for the response. For each department, we estimated the damaged in 3 different culture types (??Culture??). Our statistical individual are therefore the department crossed by the culture
2023 Apr 30
2
NaN response with gam (mgcv library)
Dear R-experts, Here below my R code. I get a NaN response for gam with mgcv library. How to solve that problem? Many thanks. ######################################################### library(mgcv) ? y=c(23,24,34,40,42,43,54,34,52,54,23,32,35,45,46,54,34,36,37,48) x1=c(0.1,0.3,0.5,0.7,0.8,0.9,0.1,0.7,0.67,0.98,0.56,0.54,0.34,0.12,0.47,0.52,0.87,0.56,0.71,0.6)
2008 Mar 27
1
dreaded p-val for d^2 of a glm / gam
OK, I really dread to ask that .... much more that I know some discussion about p-values and if they are relevant for regressions were already on the list. I know to get p-val of regression coefficients - this is not a problem. But unfortunately one editor of a journal where i would like to publish some results insists in giving p-values for the squared deviance i get out from different glm and
2018 Mar 04
0
Random effect in GAM (mgcv)
Statistics questions are largely off topic on this list, although they do sometimes intersect R programming issues, which are on topic. However, I believe a statistics list like stats.stackexchange.com might be more suitable for your query. Cheers, Bert Bert Gunter "The trouble with having an open mind is that people keep coming along and sticking things into it." -- Opus (aka
2005 Oct 05
3
testing non-linear component in mgcv:gam
Hi, I need further help with my GAMs. Most models I test are very obviously non-linear. Yet, to be on the safe side, I report the significance of the smooth (default output of mgcv's summary.gam) and confirm it deviates significantly from linearity. I do the latter by fitting a second model where the same predictor is entered without the s(), and then use anova.gam to compare the
2012 May 29
1
GAM interactions, by example
Dear all, I'm using the mgcv library by Simon Wood to fit gam models with interactions and I have been reading (and running) the "factor 'by' variable example" given on the gam.models help page (see below, output from the two first models b, and b1). The example explains that both b and b1 fits are similar: "note that the preceding fit (here b) is the same as
2005 Sep 23
1
Smooth terms significance in GAM models
hi, i'm using gam() function from package mgcv with default option (edf estimated by GCV). >G=gam(y ~ s(x0, k = 5) + s(x1) + s(x2, k = 3)) >SG=summary(G) Formula: y ~ +s(x0, k = 5) + s(x1) + s(x2, k = 3) Parametric coefficients: Estimate std. err. t ratio Pr(>|t|) (Intercept) 3.462e+07 1.965e+05 176.2 < 2.22e-16 Approximate significance of smooth