The Directed Prediction Index for Causal Direction Inference from Observational Data
Overview
The Directed Prediction Index ('DPI') is a causal discovery method for observational data designed to quantify the relative endogeneity of outcome (Y) versus predictor (X) variables in regression models. By comparing the coefficients of determination (R-squared) between the Y-as-outcome and X-as-outcome models while controlling for sufficient confounders and simulating k random covariates, it can quantify relative endogeneity, providing a necessary but insufficient condition for causal direction from a less endogenous variable (X) to a more endogenous variable (Y). Methodological details are provided at https://psychbruce.github.io/DPI/. This package also includes functions for data simulation and network analysis (correlation, partial correlation, and Bayesian Networks).
- Minor changes and improvements.
From NEWS.md in the release
Install
Health
- OK13 OK2026-08-05
- NOTE12 OK, 1 NOTE2026-08-01
- OK13 OK2026-06-09
- ERROR12 OK, 1 ERROR2026-06-08
- OK14 OK2026-03-10
Documentation
- Help pages
- 12 (3 internal)includes a package overview page
- Examples that run
- 33%3 run in a plain check · 6 only when donttest examples are enabled (R CMD check --as-cran)
- Exported functions with examples
- 100%
- Documented parameters
- 92%
- Return-value docs
- 100%
- Help pages citing references
- 17%
Downloads
Repository
8 development-tooling and community-health practices detected across 4 families in the upstream repository
Checks run against github.com/psychbruce/dpi on 2026-10-11.
The R CMD check workflow runs on Linux
GitHub Pages site last deployed 2026-02-26 · The repository has a site deploy workflow
pkgdown site last built 2026-02-26
Dependencies
Installing DPI adds 75 packages (40 with compiled code, 67 MB of source tarballs). Heaviest: stringi 11 MB, ggplot2 6.0 MB, data.table 5.7 MB.
Code & Tests
People & History
Maintainer since 2025.6 (2025)
Package metadata
- First published
- 2025-06-18
- Total releases
- 7 / 1 yrs
- License
- GPL-3 OSI
- Minimum R
- ≥ 4.0.0
- Download size
- 32 KB
Cite
Cite this package
Run in R for the authors' preferred citation:
citation("DPI")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.
From data release v2026-10-17, which the citation names so these numbers can be found later. More on citing and the projects behind them.