Skip to main content

Questions tagged [generalized-additive-model]

Generalized additive models (GAMs) are regressions that estimate nonlinear patterns in data. This tag should not be used with the `glm` tag unless the question explicitly deals with comparison of the GAMs with GLMs.

Filter by
Sorted by
Tagged with
0 votes
0 answers
2 views

I am running a GAM model with bam in the mgcv package in R. The dataset in the model is calculated from mean hourly speeds for individual fish from position data (x,y, datetime). ...
mikejwilliamson's user avatar
1 vote
0 answers
19 views

I’m working with hierarchical GAMs (HGAMs) in mgcv (using gam and eventually bam), and I’ve been testing how far I can extend the model while still keeping the results interpretable. My goal is to ...
camila's user avatar
  • 175
3 votes
1 answer
106 views

While fairly new to GAMs, I have fit a number of them recently using REML, and just obtained negative REML scores for the first time. I have read that when comparing models based on REML, the best ...
arnaudmarois's user avatar
0 votes
0 answers
44 views

I am running a GAMM model to look at the effect of temperature on the daily patterns (in radians) of an animal's movement (step length). The data is hourly, however there are individuals with hours, ...
Amelia's user avatar
  • 31
5 votes
0 answers
106 views

I delved a bit deeper lately into GAMs and I have the feeling, the more I go into detail the more questions are popping up (well, as usual, I'd say). I recognized here and there, that there are plenty ...
1 vote
1 answer
76 views

I've got a dataset describing the infestation of an insect on plants in a very large area. The data were collected using several transects. Each transect is composed of 4 plots, with multiple plants ...
JTurra's user avatar
  • 11
2 votes
0 answers
25 views

It might be a bold question, but I wanted to be sure that I am on the right track with my thoughts, since I am no mathematician or something close :) When using GAMs with a smooth-factor interaction, ...
Maki's user avatar
  • 63
3 votes
0 answers
78 views

Recently, I was asked about the partial R2 of predictors or how much each term contributes to the overall explanatory "power" of the model. I think it was a question stemming from the ...
Paul Julian's user avatar
5 votes
2 answers
113 views

I’m working with a GAM to predict bulk density (BD) as a function of depth, soil type, and land cover. The model includes a random effect for the source of the observations (SOURCE). After checking ...
Aurélien Lengrand's user avatar
0 votes
0 answers
38 views

I have a survival model for a long term mark-recap study that I am trying to apply to several populations. I have been trying to follow Pedersen et al 2019 for this, but I have variables for which I ...
ghaines's user avatar
0 votes
0 answers
14 views

I have trial-level data from 329 participants aged 18–79. Each participant completed 90 trials of an association task. Each trial includes: a within-subject factor Condition (3 levels: A, B, C; 30 ...
Wasabi's user avatar
  • 1
0 votes
0 answers
52 views

I am using GAMMs to model the probability of occurrence of a species, applying logistic regressions with mgcv::bam() to presence-pseudoabsence data. The dataset ...
airC's user avatar
  • 41
5 votes
2 answers
476 views

I am fitting the following GAM model. My response variable is aggregated counts of disease incidence at the county-level. I used log(population) as an offset. If I use it this way, I learned that it ...
Rahul's user avatar
  • 133
0 votes
0 answers
44 views

I fit the following hierarchical gam. My response variable here is Foliar total phosphorus. I have about 20 years of annual data (no gaps) and about 3-5 replicates (collections) per site. I wanted to ...
camila's user avatar
  • 175
4 votes
1 answer
86 views

I have a dataset of brain signals that were recorded simultaneously from several brain regions while participants performed a cognitive task. I have two categorical predictors (recording site, ...
AI ReiGro's user avatar
1 vote
0 answers
91 views

I am working with a GAM model to study how land cover (LC_L1_factor) affects bulk density (BD) with depth (DEPTH_M): ...
Aurélien Lengrand's user avatar
0 votes
0 answers
33 views

I’m fitting hierarchical generalized additive model (HGAMs) to model temporal trends while accounting for nested structure in the data. The goal here is to specify Site nested within Basin. The model ...
camila's user avatar
  • 175
0 votes
0 answers
50 views

Goal: Annual TP at 4 sites (18 years, ~3 plots per site per year). I fit a hierarchical GAM with a global smooth over Year plus site-specific smooths (factor–smooth interaction). I want to identify ...
camila's user avatar
  • 175
0 votes
0 answers
42 views

I'm in need of some advice on how to account for residual dependence in a fitted GAM that doesn't appear to be driven by temporal structure in the data. In summary, I am working with a long-term ...
Jeremy Hemberger's user avatar
4 votes
1 answer
122 views

I’ve been running Generalized Additive Models (GAMs) to explore temporal trends in my soil phosphorus data. I have 20 years of data at each site. I'm considering either modeling individual GAMs for ...
camila's user avatar
  • 175
1 vote
0 answers
84 views

I have implemented the following model using mgcv package ...
Rahul's user avatar
  • 133
6 votes
1 answer
142 views

I’m fitting generalized additive mixed models in R (mgcv::gam()) to study how productivity changes over time across multiple Locations. Each Location has repeated measurements from several plots. I ...
camila's user avatar
  • 175
5 votes
1 answer
188 views

I’m fitting generalized additive mixed models (GAMMs) using mgcv::gam() in R, and I’ve run into a question about the scale of model outputs. The goal of my analysis ...
camila's user avatar
  • 175
3 votes
0 answers
96 views

This is a re-post of my question here (has votes to migrate, but also required data). I can delete this version and follow instructions to migrate my OP properly, if that's preferred. This is more of ...
Nate's user avatar
  • 2,537
7 votes
1 answer
235 views

I remember learning that $p$-values from the summary() output are only approximate for generalized additive models (GAMs), but these results are a bit ...
Nate's user avatar
  • 2,537
0 votes
0 answers
39 views

I'm using the mgcv package playing around with the gam fits to my data. The following question I am trying to answer is whether the animal behaviour between the ...
Betelgeuse's user avatar
1 vote
0 answers
72 views

I am having difficulty making population-level model predictions on the response scale for a hierarchical binomial generalized additive model (GAM) that contains both a "global smoother" ...
sjohnsonbice's user avatar
0 votes
0 answers
31 views

I am developing a species distribution model for a rare, data-scarce species. To explore the effect of sample prevalence, I fitted several models with different presence–absence ratios by randomly ...
Lola Riesgo Torres's user avatar
0 votes
0 answers
53 views

I’m working on a Bayesian ordinal regression model using brms to estimate coral bleaching severity levels (4 categories: None, Mild, Moderate, Severe) based on thermal stress. My data consists of two ...
Virginie Bornarel's user avatar
3 votes
1 answer
107 views

I am trying to appropriately propagate uncertainty from my predicted datasets following a GAM model. Essentially, I have weekly counts of data (i.e., egg counts), but want to calculate cumulative ...
lmbradley's user avatar
1 vote
1 answer
81 views

I am currently attempting to model the effects of land management on ecosystem stability. As an example I use deviations from a long-term mean in plant productivity as my response variable (numeric, ...
Uviero's user avatar
  • 11
9 votes
3 answers
479 views

Can individual components of compositional data be made into separate covariates in a single model? I want to use average seagrass cover by species as covariates to separate the effects by species of ...
Nate's user avatar
  • 2,537
3 votes
1 answer
71 views

I am performing a regression analysis using a generalized additive model, 2 spline terms and 12 linear terms. When I use the summary(gam_model) command, I get some F statistics for my 2 spline terms. ...
sandgrove43's user avatar
4 votes
1 answer
125 views

I’m working on a project that models species distribution and co-occurrence using full-subset generalized additive mixed models (GAMMs) in R, specifically with the mgcv and FSSgam packages. I’ve ...
Kristin's user avatar
  • 41
1 vote
0 answers
49 views

I am trying to run a logistical GAM of probability of occurrence for several fish species from recreational fishing data using the mgcv package in R. The model uses different oceanographic variables ...
Anita Giraldo's user avatar
3 votes
1 answer
137 views

For baseline I run an OLS with several covariates and high dimensional fixed effects. I also want to run GAM to check if one specific term has a non-linear effect. To do so I first tried with a full ...
impala's user avatar
  • 33
1 vote
0 answers
112 views

I've fixed my model and incorporated all the terms I believe have an effect on my response (abundance of a single species), but I'm stuck on how to interpret the long-term trend plot, ...
Nate's user avatar
  • 2,537
6 votes
1 answer
205 views

In many regression settings where we minimize a loss function directly (e.g., squared error in linear regression), the performance measure flows naturally from the loss function used during training. ...
August Edwards's user avatar
0 votes
0 answers
100 views

I am using GAM with the mgcv package in R to predict a discrete variable scaled to [0, 1]. The variable was under a beta distribution (checked with ...
Tuan-Anh Tran's user avatar
1 vote
1 answer
146 views

This is a follow-up question to my last one (larger dataset found here). I was able to code a variogram (gstat::variogram()), but the resultant plot is a bit ...
Nate's user avatar
  • 2,537
1 vote
1 answer
102 views

I am writing a model equation for a generalized additive model that I am using. I have a continuous response variable (not necessarily normally distributed) and I have 14 predictor variables. Let's ...
sandgrove43's user avatar
2 votes
0 answers
90 views

I am developing a prediction model to predict a binary outcome. I am fitting this as a gam in the R package mgcv. All predictors are fitted as smooth terms, including random effects. Is it advisable ...
user167591's user avatar
  • 1,173
2 votes
0 answers
105 views

I am working with a Generalized Additive Model for Location, Scale, and Shape (GAMLSS) and trying to determine the optimal $\lambda$ values for LASSO-penalized regression using cross-validation. ...
Joshua Oehmen's user avatar
2 votes
1 answer
78 views

I am using GAMLSS with family = NBI() and modeling $\mu$ and $\sigma$ as smooth functions of $x$. The true data-generating process for $\mu$ is $\mu = \exp(1 + 0.3x)...
Joshua Oehmen's user avatar
1 vote
2 answers
131 views

My main goal is to compare the effect strength of two predictors ($X_1$ and $X_2$) on a response across different Sites/Years in either GLM or GAM. This leads to specific sub-questions related to my ...
katja.kr's user avatar
8 votes
1 answer
269 views

I'm currently working with Generalized Additive Models for Location, Scale, and Shape (GAMLSS) and considering incorporating LASSO regularization. However, I'm wondering whether it even makes sense to ...
Joshua Oehmen's user avatar
4 votes
2 answers
133 views

I have a very small dataset of seabird count data (12 observations/28 samples prions, 22/28 shearwaters, 12/22 storm petrels) and am interested in the association of these taxa and zooplankton ...
daragh brown's user avatar
6 votes
1 answer
181 views

I would like to fit a GAM that controls for phylogenetic relatedness among observations. I found and adopted this blog post by Nicholas Clark which introduces phylogenetic relationships by adding the ...
mluerig's user avatar
  • 865

1
2 3 4 5
23