Skip to content

lddmm

1.0.0Package record

Longitudinal Drift-Diffusion Mixed Models (LDDMM)

0packages depend
2.6Kdownloads / year
97.9%test coverage
13/13flavors OK

Overview

About

Implementation of the drift-diffusion mixed model for category learning as described in Paulon et al. (2021) doi:10.1080/01621459.2020.1801448.

Changes in 1.0.0

This major release introduces an improved sampler.

Model and defaults

  • Every participant has one random effect curve for correct responses and one for incorrect responses (random_effects = "correct-incorrect", the new default). A single curve for both is available with random_effects = "shared".
  • The maximum number of clusters at each block defaults to min(K^2, 2K) (8 for 4 categories) and can be set with z_max.
  • Spline coefficients that start a curve have the normal prior of article eq. (9), with mean and variance set from the data (hypers$mu_beta0_*, hypers$sigma2_beta0_*).
  • The smoothness of the fixed effects has a half-Cauchy prior on its standard deviation (scale hypers$s_sigma_*). The upper limits on the variance parameters are documented hyperparameters (hypers$sigma2_1_max, hypers$sigma2_us_max, hypers$sigma2_ua_max).

Improved sampler

  • A single implementation serves all boundary models, and the cluster-label and random-effect updates run in C++. Fits are about 12-21 times faster on the tone learning data.
  • The cluster labels are updated with an exact locally informed Hamming ball sampler, and the cluster-specific spline coefficients with proposals built from the prior of article eq. (9).
  • New joint moves improve mixing: a translation between fixed and random effects, a rescaling of the random effects together with their variances, and shifts of the offsets together with the drift and boundary levels.
  • Coefficients of unused clusters are drawn close to those of the clusters in use (hypers$pseudo_sd), so that curves move between clusters more easily.
  • Random effects start from each participant's moment estimates, and proposal scales are tuned during burn-in only, in batches of 50 iterations.
Show all changes in 1.0.0Hide the rest of the changes in 1.0.0
  • Response-time distributions are evaluated on the log scale, which keeps them accurate for slow responses.

Other changes

  • New plot_predictive() for posterior predictive checks of the decisions and the response times.
  • Two worked examples are installed with the package (system.file("examples", package = "lddmm")): toy_example.R analyses the bundled data, and toy_simulation.R simulates data with known parameters and compares the posterior with the truth. The README and the vignette walk through fitting, posterior predictive checks and convergence diagnostics.
  • New arguments save_z (store cluster labels), save_loglik, informed, verbose and debug_checks; the fit also reports acceptance rates and the settings used.
  • LDDMM() checks its input and reports problems with the data.
  • log_likelihood_ind() returns a plain vector, and compute_WAIC() is computed on the log scale.
  • plot_accuracy() works without attaching dplyr.
  • The package no longer depends on gtools, LaplacesDemon, plyr, RColorBrewer, RcppProgress and rgen.
  • Unit tests, and validation scripts in tests/validation/ (a Geweke joint distribution test, invariance tests of individual updates, and a simulate-and-recover study).
  • The documentation states that response times are in seconds.

From NEWS.md in the release

Install

Health

CRAN checks
13OK
Slowest check: 3.7 min · r-devel-windows-x86_64
Status changes
  • OK13 OK2026-08-05
  • NOTE12 OK, 1 NOTE2026-08-01
  • OK14 OK2026-04-22
  • ERROR13 OK, 1 ERROR2026-04-18
  • OK14 OK2026-04-10
Show 2 earlier changesHide 2 earlier changes
  • ERROR13 OK, 1 ERROR2026-04-09
  • OK14 OK2026-03-10
Advisories

none known

Documentation

In release 1.0.0
READMEYes · 828 wordsVignettesYes · 1 · dynamicNEWSYes · 100% structured · mentions 1.0.0Citation fileNoWebsitenot declared in DESCRIPTION
Help pages
15 (1 internal)includes a package overview page
Examples that run
no examples
Exported functions with examples
0%
Documented parameters
100%
Return-value docs
100%
Help pages citing references
7%
Vignettes (1)

Downloads

2.6K
CRAN downloads in the past year
Rank #16,007 · ~7/day · ~220/mo
Daily download trend is not available in this view yet.
28430 days
77690 days
2.6K1 year
Compare downloads with other packages →
Also on349 r2u7 autocran

Repository

3Stars
0Forks
0Open issues
0Open PRs
5Releases
Last activity 2026-10-23
Responsiveness
How these are sampled
PRs merged (all time)
50%
Median days to close, 50 most recently updated closed issues
not measured
Median days to close, 50 most recently updated closed PRs
not measured
PracticesBeta

Repository github.com/giorgiopaulon/lddmm is linked, but repository-practices checks have not run for it yet.

How this is detected·Detection ruleset v4 (2026-10-20)

Dependencies

Declared dependencies
12 external dependencies (excludes base and recommended)

Installing lddmm adds 34 packages (19 with compiled code, 32 MB of source tarballs). Heaviest: stringi 11 MB, ggplot2 6.0 MB, Rcpp 1.8 MB.

Depends (1)
R >= 4.1.0
LinkingTo (2)
Enhances (0)
none
Reverse dependencies
0direct
0indirect

Nothing depends on this yet.

Datasets

People & History

People (2)
Author, Maintainer since 0.1.0 (2021)
Author, Contributor
Releases (7)

Pick two releases to compare their code metrics.

  • R
    R 4.6.0 released · 2026-04-24
  • R
    R 4.5.0 released · 2025-04-11
  • R
    R 4.4.0 released · 2024-04-24
  • 1.0.0Latest
    record
    2024-01-17 · current release · diff ↗ ·
    removed 1 export
    data
    added 1 export
    plot_predictive
  • 0.4.2
    record
    2024-01-17 · diff ↗
  • 0.4.0
    record
    2023-06-06 · diff ↗
  • R
    R 4.3.0 released · 2023-04-21
  • 0.3.0
    record
    2023-03-26 · diff ↗ ·
    added 2 exports
    log_likelihood_ind, compute_WAIC
  • 0.2.1
    record
    2023-01-31 · diff ↗
  • 0.2.0
    record
    2023-01-28 · diff ↗
  • R
    R 4.2.0 released · 2022-04-22
  • 0.1.0
    record
    2021-11-08
  • R
    R 4.1.0 released · 2021-05-18

Package metadata

First published
2021-11-08
Total releases
7 / 5 yrs
License
MIT + file LICENSE OSI
Minimum R
≥ 4.1.0
Bundled data
75 KB / 1 file
Download size
1.3 MB

Cite

Cite this package

Run in R for the authors' preferred citation:

citation("lddmm")
Paulon, G., & Sarkar, A. (2026). lddmm: Longitudinal Drift-Diffusion Mixed Models (LDDMM) (Version 1.0.0) [Computer software]. https://doi.org/10.32614/CRAN.package.lddmm

This package has no citation file, so citation() returns this entry built from DESCRIPTION.

Cite the R Observatory

For a number measured here: a download total, a coverage figure, an archival date.

APA

Balamuta, J. J. (2026). R Observatory: Metrics for lddmm version 1.0.0 [Data set]. HJJB, LLC. Data release v2026-10-23. https://doi.org/10.5281/zenodo.21843040

From data release v2026-10-23, which the citation names so these numbers can be found later. More on citing and the projects behind them.

Report a problem with this page →

Privacy choices

These apply to this browser and are stored on this device only. Nothing about your choice is sent to us.

Read the privacy policy