umx (version 4.0.0)

umxPlotGxE: Plot the results of a GxE univariate test for moderation of ACE components.

Description

Plot GxE results (univariate environmental moderation of ACE components). Options include plotting the raw and standardized graphs separately, or in a combined panel. You can also set the label for the x axis (xlab), and choose the location of the legend.

Usage

umxPlotGxE(
  x,
  xlab = NA,
  location = "topleft",
  separateGraphs = FALSE,
  acergb = c("red", "green", "blue", "black"),
  ...
)

Arguments

x

A fitted umxGxE() model to plot

xlab

String to use for the x label (default = NA, which will use the variable name)

location

Where to plot the legend (default = "topleft") see ?legend for alternatives like bottomright

separateGraphs

(default = FALSE)

acergb

Colors to use for plot c(a = "red", c = "green", e = "blue", tot = "black")

...

Optional additional parameters

Value

None

References

See Also

Other Plotting functions: plot.MxLISRELModel(), plot.MxModel(), umxPlotACEcov(), umxPlotACEv(), umxPlotACE(), umxPlotCP(), umxPlotGxEbiv(), umxPlotIP(), umxPlotSexLim(), umxPlotSimplex(), umx

Examples

Run this code
# NOT RUN {
require(umx)
data(twinData)
twinData$age1 = twinData$age2 = twinData$age
mzData = subset(twinData, zygosity == "MZFF")
dzData = subset(twinData, zygosity == "DZFF")
m1= umxGxE(selDVs= "bmi", selDefs= "age", dzData= dzData, mzData= mzData, sep="", tryHard="yes")
plot(m1)
# Directly call the umx function
umxPlotGxE(x = m1, xlab = "SES", separateGraphs = TRUE, location = "topleft")

# }

Run the code above in your browser using DataLab