umxDiffMZ {umx}R Documentation

MZ differences method for testing evidence for causality.

Description

umxDiffMZ implements the simple twin1-twin2 based correlation method, e.g. De Moor (2008), in which MZ differences on a variable x asserted to be causal of an outcome variable y are tested for association with differences on y. The logic of the design is shown below:

Figure: MZ differences model

Usage

umxDiffMZ(
  x,
  y,
  data,
  sep = "_T",
  mzZygs = c("MZFF", "MZMM"),
  zyg = "zygosity",
  labxy = c(-1.2, 1.8),
  xylim = c(NA, NA),
  digits = 2
)

Arguments

x

Presumed causal variable, e.g. "effort"

y

Presumed caused outcome, e.g. "score"

data

Dataframe containing the twin data.

sep

The separator "_T" used to make twin var names from x and y.

mzZygs

The MZ zygosity codes c("MZFF", "MZMM")

zyg

The column containing "zygosity" data

labxy

Where to locate the R2 label (default = c(x=-2,y=3))

xylim

= clip x any axes to range, e.g c(-3,-3)

digits

Rounding for beta (def2)

Details

Example output is shown below, with the fitted line and fit inscribed. The plot is just a ggplot graph that is returned and can be edited and formatted.

Figure: MZ differences model

For a more sophisticated linear mixed model approach, see umxDiscTwin().

Value

References

See Also

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

Examples

data(twinData)
umxDiffMZ(x="ht", y="wt", labxy = c(-.5, 3), data = twinData, sep = "")
umxDiffMZ(x="ht", y="wt", xylim = c( -2, 2), data = twinData, sep = "")

[Package umx version 4.20.0 Index]