Package: galamm 0.4.0

Øystein Sørensen

galamm: Generalized Additive Latent and Mixed Models

Estimates generalized additive latent and mixed models using maximum marginal likelihood, as defined in Sorensen et al. (2023) <doi:10.1007/s11336-023-09910-z>, which is an extension of Rabe-Hesketh and Skrondal (2004)'s unifying framework for multilevel latent variable modeling <doi:10.1007/BF02295939>. Efficient computation is done using sparse matrix methods, Laplace approximation, and automatic differentiation. The framework includes generalized multilevel models with heteroscedastic residuals, mixed response types, factor loadings, smoothing splines, crossed random effects, and combinations thereof. Syntax for model formulation is close to 'lme4' (Bates et al. (2015) <doi:10.18637/jss.v067.i01>) and 'PLmixed' (Rockwood and Jeon (2019) <doi:10.1080/00273171.2018.1516541>).

Authors:Øystein Sørensen [aut, cre], Douglas Bates [ctb], Ben Bolker [ctb], Martin Maechler [ctb], Allan Leal [ctb], Fabian Scheipl [ctb], Steven Walker [ctb], Simon Wood [ctb]

galamm_0.4.0.tar.gz
galamm_0.4.0.zip(r-4.7)galamm_0.4.0.zip(r-4.6)galamm_0.4.0.zip(r-4.5)
galamm_0.4.0.tgz(r-4.6-x86_64)galamm_0.4.0.tgz(r-4.6-arm64)galamm_0.4.0.tgz(r-4.5-x86_64)galamm_0.4.0.tgz(r-4.5-arm64)
galamm_0.4.0.tar.gz(r-4.7-arm64)galamm_0.4.0.tar.gz(r-4.7-x86_64)galamm_0.4.0.tar.gz(r-4.6-arm64)galamm_0.4.0.tar.gz(r-4.6-x86_64)
galamm_0.4.0.tgz(r-4.6-emscripten)
manual.pdf |manual.html
card.svg |card.png
galamm/json (API)

# Install 'galamm' in R:
install.packages('galamm', repos = c('https://lcbc-uio.r-universe.dev', 'https://cloud.r-project.org'))

Bug tracker:https://github.com/lcbc-uio/galamm/issues

Pkgdown/docs site:https://lcbc-uio.github.io

Uses libs:
  • c++– GNU Standard C++ Library v3
Datasets:
  • cognition - Simulated Data with Measurements of Cognitive Abilities
  • diet - Diet Data
  • epilep - Epilepsy Data
  • hsced - Example Data with Heteroscedastic Residuals
  • latent_covariates - Simulated Data with Latent and Observed Covariates Interaction
  • latent_covariates_long - Simulated Longitudinal Data with Latent and Observed Covariates Interaction
  • lifespan - Simulated Dataset with Lifespan Trajectories of Three Cognitive Domains
  • mresp - Simulated Mixed Response Data
  • mresp_hsced - Simulated Mixed Response Data with Heteroscedastic Residuals

On CRAN:

Conda:

generalized-additive-modelshierarchical-modelsitem-response-theorylatent-variable-modelsstructural-equation-modelscpp

7.62 score 34 stars 31 scripts 591 downloads 18 exports 56 dependencies

Last updated from:e9e27fcb66. Checks:13 OK. Indexed: yes.

TargetResultTimeFilesSyslog
linux-devel-arm64OK238
linux-devel-x86_64OK258
source / vignettesOK247
linux-release-arm64OK240
linux-release-x86_64OK249
macos-release-arm64OK193
macos-release-x86_64OK329
macos-oldrel-arm64OK173
macos-oldrel-x86_64OK414
windows-develOK250
windows-releaseOK296
windows-oldrelOK237
wasm-releaseOK153

Exports:appraisederivativesdrawextract_optim_parametersfactor_loadingsfixefgalammgalamm_controlgfamplot_smoothqqmathranefresponsesslt2t2lVarCorr

Dependencies:BHbootcachemclicpp11dplyrfarverfastmapgenericsggokabeitoggplot2gluegratiagtableisobandlabelinglatticelifecyclelme4magrittrMASSMatrixmemoisemgcvminqamiraimvnfastnanonextnlmenloptrpatchworkpillarpkgconfigpurrrR6rbibutilsRColorBrewerRcppRcppArmadilloRcppEigenRdpackreformulasrlangS7scalesstatmodstringistringrtibbletidyrtidyselecttweedieutf8vctrsviridisLitewithr

Computational Scaling

Rendered fromscaling.Rmdusingknitr::rmarkdownon Jun 03 2026.

Last update: 2025-09-28
Started: 2023-10-16

Generalized Linear Mixed Models with Factor Structures

Rendered fromglmm_factor.Rmdusingknitr::rmarkdownon Jun 03 2026.

Last update: 2025-12-21
Started: 2023-08-11

Heteroscedastic Linear Mixed Models

Rendered fromlmm_heteroscedastic.Rmdusingknitr::rmarkdownon Jun 03 2026.

Last update: 2025-12-21
Started: 2023-08-13

Interactions Between Latent and Observed Covariates

Rendered fromlatent_observed_interaction.Rmdusingknitr::rmarkdownon Jun 03 2026.

Last update: 2025-11-28
Started: 2023-09-25

Introduction

Rendered fromgalamm.Rmdusingknitr::rmarkdownon Jun 03 2026.

Last update: 2024-09-16
Started: 2023-08-15

Linear Mixed Models with Factor Structures

Rendered fromlmm_factor.Rmdusingknitr::rmarkdownon Jun 03 2026.

Last update: 2025-11-28
Started: 2023-08-11

Models with Mixed Response Types

Rendered frommixed_response.Rmdusingknitr::rmarkdownon Jun 03 2026.

Last update: 2025-12-21
Started: 2023-08-13

Optimization

Rendered fromoptimization.Rmdusingknitr::rmarkdownon Jun 03 2026.

Last update: 2025-11-25
Started: 2023-08-14

Posterior Sampling

Rendered fromposterior_sampling.Rmdusingknitr::rmarkdownon Jun 03 2026.

Last update: 2025-12-21
Started: 2025-12-10

Semiparametric Latent Variable Modeling

Rendered fromsemiparametric.Rmdusingknitr::rmarkdownon Jun 03 2026.

Last update: 2025-12-21
Started: 2023-08-14

Readme and manuals

Help Manual

Help pageTopics
Compare likelihoods of galamm objectsanova.galamm
Gratia style model diagnostic plotsappraise appraise.galamm
Extract galamm coefficientscoef.galamm
Simulated Data with Measurements of Cognitive Abilitiescognition
Confidence intervals for model parametersconfint.galamm
Derivatives of estimated smooth via finite differencesderivatives derivatives.galamm
Extract deviance of galamm objectdeviance.galamm
Diet Datadiet
Draw method for galamm objectsdraw draw.galamm
Epilepsy Dataepilep
Extract parameters from fitted model for use as initial valuesextract_optim_parameters extract_optim_parameters.galamm
Extract factor loadings from galamm objectfactor_loadings factor_loadings.galamm
Extract family or families from fitted galammfamily.galamm
Extract model fitted valuesfitted.galamm
Extract fixed effects from galamm objectsfixef fixef.galamm
Extract formula from fitted galamm objectformula.galamm
Fit a generalized additive latent and mixed modelgalamm
Control values for galamm fitgalamm_control
Class "galamm"galammObject
Grouped familiesgfam
Example Data with Heteroscedastic Residualshsced
Simulated Data with Latent and Observed Covariates Interactionlatent_covariates
Simulated Longitudinal Data with Latent and Observed Covariates Interactionlatent_covariates_long
Simulated Dataset with Lifespan Trajectories of Three Cognitive Domainslifespan
Extract Log-Likelihood of galamm ObjectlogLik.galamm
Extract the model frame from a galamm objectmodel.frame.galamm
Simulated Mixed Response Datamresp
Simulated Mixed Response Data with Heteroscedastic Residualsmresp_hsced
Extract the Number of Observations from a galamm Fitnobs.galamm
Plot smooth terms for galamm fitsplot_smooth plot_smooth.galamm
Diagnostic plots for galamm objectsplot.galamm
Predictions from a model at new data valuespredict.galamm
Print method for GALAMM fitsprint.galamm
Print method for summary GALAMM fitsprint.summary.galamm
Print method for variance-covariance objectsprint.VarCorr.galamm
Quantile-quantile plots for galamm objectsqqmath qqmath.galamm
Extract random effects from galamm object.ranef ranef.galamm
Residuals of galamm objectsresiduals.galamm
Extract response valuesresponse
Set up smooth term with factor loadings sl
Extract square root of dispersion parameter from galamm objectsigma.galamm
Summarizing GALAMM fitssummary.galamm
Set up smooth term with factor loadingt2 t2l
Extract variance and correlation components from modelVarCorr VarCorr.galamm
Calculate variance-covariance matrix for GALAMM fitvcov.galamm