Package: RMediation 1.6.1

RMediation: Mediation Analysis Confidence Intervals

Computes confidence intervals for nonlinear functions of model parameters (e.g., product of k coefficients) in single-level and multilevel structural equation models. Methods include the distribution of the product, Monte Carlo simulation, and bootstrap methods. It also performs the Model-Based Constrained Optimization (MBCO) procedure for hypothesis testing of indirect effects. References: Tofighi, D., and MacKinnon, D. P. (2011). RMediation: An R package for mediation analysis confidence intervals. Behavior Research Methods, 43, 692-700. <doi:10.3758/s13428-011-0076-x>; Tofighi, D., and Kelley, K. (2020). Improved inference in mediation analysis: Introducing the model-based constrained optimization procedure. Psychological Methods, 25(4), 496-515. <doi:10.1037/met0000259>; Tofighi, D. (2020). Bootstrap Model-Based Constrained Optimization Tests of Indirect Effects. Frontiers in Psychology, 10, 2989. <doi:10.3389/fpsyg.2019.02989>.

Authors:Davood Tofighi [aut, cre]

RMediation_1.6.1.tar.gz
RMediation_1.6.1.zip(r-4.7)RMediation_1.6.1.zip(r-4.6)RMediation_1.6.1.zip(r-4.5)
RMediation_1.6.1.tgz(r-4.6-any)RMediation_1.6.1.tgz(r-4.5-any)
RMediation_1.6.1.tar.gz(r-4.7-any)RMediation_1.6.1.tar.gz(r-4.6-any)
RMediation_1.6.1.tgz(r-4.6-emscripten)
manual.pdf |manual.html
DESCRIPTION |NEWS
card.svg |card.png
RMediation/json (API)

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

Bug tracker:https://github.com/data-wise/rmediation/issues

Pkgdown/docs site:https://data-wise.github.io

Datasets:
  • memory_exp - Memory Experiment Data Description from MacKinnon et al., 2018

On CRAN:

Conda:

causal-inferenceconfidence-intervalslikelihood-ratio-testmediationmediation-analysis

7.55 score 2 stars 1 packages 65 scripts 672 downloads 11 mentions 19 exports 11 dependencies

Last updated from:e9b6d6e208 (on main). Checks:9 OK. Indexed: yes.

TargetResultTimeFilesSyslog
linux-devel-x86_64OK170
source / vignettesOK209
linux-release-x86_64OK162
macos-release-arm64OK118
macos-oldrel-arm64OK110
windows-develOK129
windows-releaseOK130
windows-oldrelOK133
wasm-releaseOK154

Exports:cdfcici_mediation_dataci_serial_mediation_datadist_quantilembcoMBCOResultmedcimedci_prototypep_prod3pMCpprodnormalpprodnormal3ProductNormalProductNormal2ProductNormal3qMCqprodnormaltidy

Dependencies:backportscheckmatecubaturelavaanMASSmnormtnumDerivpbivnormquadprogRcppS7

Comparing Confidence Interval Methods in RMediation
Introduction | Overview of Methods | Method Comparison | Performance and Accuracy Comparison | When to Use Each Method | Distribution of Product (DOP) | Monte Carlo (MC) | Asymptotic Normal | Working with S7 Classes | Practical Recommendations | Conclusion

Last update: 2026-06-30
Started: 2025-12-04

Getting Started with RMediation
Introduction | Basic Usage | Single Mediator Analysis | Multiple Mediators | Three-Variable Indirect Effects (ProductNormal3) | Using S7 Classes | Available Methods | Integration with Structural Equation Modeling | Validation and Error Handling | Conclusion

Last update: 2026-06-30
Started: 2025-12-04

Serial Mediation with medfit
Why this vignette | A serial chain from a lavaan fit | The same chain from lm/glm fits | Graceful degradation without medfit | See also

Last update: 2026-06-30
Started: 2026-06-19