Package: MR.RGM
Title: Bayesian Multivariable Bidirectional Mendelian Randomization
Version: 0.1.3
Authors@R: 
    c(person("Bitan", "Sarkar", email = "bitansarkar010899@gmail.com", role = c("aut", "cre")), person("Yang", "Ni", email = "yangni87@gmail.com", role = "aut"))
Description: Fits multivariable bidirectional Mendelian randomization networks with Bayesian directed cyclic graphical models (reciprocal graphical models; Ni, Ji and Mueller (2018) <doi:10.1214/17-BA1087>), an earlier version of which is described in Sarkar and Ni (2025) <doi:10.1093/bioinformatics/btaf130>. The causal effects among the responses, which may form directed cycles, are estimated with spike-and-slab or threshold priors, and posterior probabilities of network motifs are provided. With a known instrument-response map the instrument effects obey the exclusion restrictions; with an unrestricted map they are selected by a spike-and-slab prior, which allows invalid instruments (horizontal pleiotropy). The input can be individual-level data, the second-moment matrices of one sample, or marginal instrument-response regressions, with optional measured covariates. The error covariance can be diagonal, inverse-Wishart, or a stochastic search structure learning prior (Wang (2015) <doi:10.1214/14-BA916>) whose inclusion indicators describe unmeasured confounding among the responses. Inference is by Markov chain Monte Carlo with exact Gibbs updates of the instrument effects and adaptive random-walk Metropolis updates of the causal effects (Roberts and Rosenthal (2009) <doi:10.1198/jcgs.2009.06134>); the fitting function reports diagnostics of weak instruments, weak identification and convergence.
License: GPL (>= 3)
Encoding: UTF-8
URL: https://github.com/bitansa/MR.RGM
BugReports: https://github.com/bitansa/MR.RGM/issues
Imports: Rcpp, stats, utils, igraph, GIGrvg
Suggests: testthat (>= 3.1.5)
LinkingTo: Rcpp, RcppArmadillo, GIGrvg
Config/testthat/edition: 3
Config/roxygen2/version: 8.1.0
NeedsCompilation: yes
Packaged: 2026-11-07 20:52:23 UTC; bitansarkar
Author: Bitan Sarkar [aut, cre],
  Yang Ni [aut]
Maintainer: Bitan Sarkar <bitansarkar010899@gmail.com>
Repository: CRAN
Date/Publication: 2026-11-07 22:20:29 UTC
