umxMRDoC: Extends Mendelian randomization with the twin design to test...

View source: R/umxMRDoC.R

umxMRDoCR Documentation

Extends Mendelian randomization with the twin design to test evidence of causality

Description

Testing causal claims is often difficult due to an inability to conduct experimental randomization of traits and situations to people. When twins are available, even when measured on a single occasion, the pattern of cross-twin cross-trait correlations can (given distinguishable modes of inheritance for the two traits) falsify causal hypotheses.

umxMRDoC implements a 2-group model to form latent variables for each of two traits, and allows testing whether trait 1 causes trait 2, vice-versa, or even reciprocal causation. This is robust to several types of confounding due to the instrumental variable approach included in the model.

This function applies both the MRDoC model and the MRDoC2 model depending on how many PRSs are passed as arguments.

Usage

umxMRDoC(
  data = NULL,
  pheno,
  prss = NULL,
  mzData = NULL,
  dzData = NULL,
  sibsData = NULL,
  zygosity = "zygosity",
  sep = "_T",
  summary = !umx_set_silent(silent = TRUE),
  name = NULL,
  autoRun = getOption("umx_auto_run"),
  sibs = FALSE,
  type = "FIML",
  tryHard = c("no", "yes", "ordinal", "search"),
  optimizer = NULL,
  covar = NULL,
  batteries = c("scale"),
  method = "Mehta",
  verbose = FALSE
)

Arguments

data

= NULL If building the MZ and DZ datasets internally from a complete data set.

pheno

Phenotypes of interest, order matters ("exposure", "outcome")

prss

Polygenic score(s). If a single one is passed MRDoC is run, MRDoC2 otherwise.

mzData

The MZ dataframe

dzData

The DZ dataframe

sibsData

The unrelated sibs dataframe, requires "sibs" as an extra zygosity level.

zygosity

= "zygosity" (for the data= method of using this function).

sep

The separator in twin variable names, default = "_T", e.g. "dep_T1".

summary

Optionally show a summary.

name

The name of the model (defaults to either "MRDoC" or "MRDoC2).

autoRun

Whether to run the model (default), or just to create it and return without running.

sibs

NEEDS DOCUMENTING (FALSE)

type

Basic switch for estimation type. WLS tends to work really well in MRDoC, it saves you time.

tryHard

Default ('no') uses normal mxRun. "yes" uses mxTryHard. Other options: "ordinal", "search".

optimizer

Optionally set the optimizer (default NULL does nothing).

covar

= Covariates that will be regressed on X and Y phenotypes.

batteries

Batteries included, currently scales continuous variables by default, "dump" will return data for inspection. Use NULL for disabling all.

method

Method for handling ordinal variables, defaults to Mehta.

verbose

Outputs the pre-processing steps/warnings.

Value

  • OpenMx::mxModel() of subclass MxModelMRDoC

References

  • Minica CC, Dolan CV, Boomsma DI, et al. (2018) Extending Causality Tests with Genetic Instruments: An Integration of Mendelian Randomization with the Classical Twin Design. Behavior Genetics 48(4): 337-349. \Sexpr[results=rd]{tools:::Rd_expr_doi("10.1007/s10519-018-9904-4")}

  • McGue, M., Osler, M., & Christensen, K. (2010). Causal Inference and Observational Research: The Utility of Twins. Perspectives on Psychological Science, 5, 546-556. \Sexpr[results=rd]{tools:::Rd_expr_doi("10.1177/1745691610383511")}

  • Castro-de-Araujo LFS, Singh M, Zhou Y, et al. (2022) MR-DoC2: Bidirectional Causal Modeling with Instrumental Variables and Data from Relatives. Behavior Genetics. \Sexpr[results=rd]{tools:::Rd_expr_doi("10.1007/s10519-022-10122-x")}

See Also

  • umxDoC()

Other Twin Modeling Functions: power.ACE.test(), umx, umxACE(), umxACEcov(), umxACEv(), umxCP(), umxDiffMZ(), umxDiscTwin(), umxDoC(), umxDoCp(), umxGxE(), umxGxE_window(), umxGxEbiv(), umxIP(), umxReduce(), umxReduceACE(), umxReduceGxE(), umxRotate.MxModelCP(), umxSexLim(), umxSimplex(), umxSummarizeTwinData(), umxSummaryACE(), umxSummaryACEv(), umxSummaryDoC(), umxSummaryGxEbiv(), umxSummarySexLim(), umxSummarySimplex(), umxTwinMaker()

Examples

## Not run: 

# ================
# = 1. Load Data =
# ================
data(docData)
mzData  = subset(docData, zygosity %in% c("MZFF", "MZMM"))
dzData  = subset(docData, zygosity %in% c("DZFF", "DZMM"))

# ============================
# = 2. Make a MRDoC2 model   =
# ============================
out = umxMRDoC(mzData = mzData, dzData = dzData,  
pheno = c("varA1", "varA2"), prss = c("varB1", "varB2") )

## End(Not run)

tbates/umx documentation built on April 13, 2025, 7:22 a.m.