tidyILD

A reproducible, tidyverse-style framework for intensive longitudinal data (ILD) analysis in R, with built-in methodological safeguards, provenance tracking, and reporting tools.
Author: Alex Litovchenko.

Install

remotes::install_github("alitovchenko/tidyILD")

Backend validation benchmarks (developers / CI)

From a source checkout of the package (directory containing DESCRIPTION), optional cross-backend simulation benchmarks can be run locally:

Rscript scripts/run-backend-validation-benchmarks.R --tier smoke --out-dir /tmp/bench
Rscript scripts/check-backend-validation-thresholds.R \
  --summary /tmp/bench/benchmark_summary.csv \
  --thresholds inst/benchmarks/thresholds-smoke.json \
  --out /tmp/bench/benchmark_checks.csv

This uses pkgload::load_all() when available. Tiers: smoke (fast), nightly, full — see inst/dev/BACKEND_VALIDATION_BENCHMARK_CONTRACT.md. GitHub Actions workflow: .github/workflows/backend-validation-benchmarks.yml (scheduled + manual dispatch; artifacts uploaded).

Quick start

library(tidyILD)

# Prepare: validate time structure, add .ild_* columns and metadata
d <- data.frame(
  id = rep(1:3, each = 5),
  time = rep(as.POSIXct(0:4 * 3600, origin = "1970-01-01"), 3),
  mood = rnorm(15)
)
x <- ild_prepare(d, id = "id", time = "time", gap_threshold = 7200)

# Inspect (summary tibble + list)
ild_summary(x)

# Within-between decomposition
x <- ild_center(x, mood)

# Spacing-aware lags (max_gap from metadata if omitted)
x <- ild_lag(x, mood, mode = "gap_aware", max_gap = 7200)

# Missingness (summary tibble + plot + by_id)
ild_missing_pattern(x, vars = "mood")

# Fit and report: tidy fixed effects, fitted vs observed, residual ACF + QQ
fit <- ild_lme(mood ~ 1 + (1 | id), data = x, ar1 = FALSE, warn_no_ar1 = FALSE)
tidy_ild_model(fit)
ild_plot(fit, type = "fitted")
ild_plot_predicted_trajectory(fit, time_var = ".ild_seq") # observed + fitted vs time
diag <- ild_diagnostics(fit); diag; plot_ild_diagnostics(diag)
bundle <- ild_diagnose(fit) # diagnostics bundle; use ild_autoplot(bundle, ...)

Pipeline

Vignettes

pkgdown site

Documentation and vignettes are built with pkgdown. From the package root: pkgdown::build_site(). Config: _pkgdown.yml.

Version tags

Release tags follow vMAJOR.MINOR.PATCH and are listed in version order with:

git tag -l 'v*' --sort=version:refname

Current tags: v0.0.1, v0.2.0, v0.3.0 (each annotated message is tidyILD <version>).

License

MIT.