desc.effects.mediation function

Describe the effects from a mediation object

Describe the effects from a mediation object

Describe the effects, and calculate standard errors and confidence intervals from a mediation object

## S3 method for class 'mediation' desc.effects(x, y_outcome = NULL, ...)

Arguments

  • x: A mediation object
  • y_outcome: The outcome; if NULL, then Y must have been provided to the original mediation function.
  • ...: Additional arguments..

Returns

  • results: effects, standard errors, and confidence intervals of a mediation object

Examples

data("tMdat") ## tMdat is small simulated data set included in twangMediation for ## demonstrating the functions. See ?tMdat for details fit.es.max <- wgtmed(M ~ w1 + w2 + w3, data = tMdat, a_treatment = "A", y_outcome = "Y", total_effect_wts = tMdat$te.wgt, method = "ps", ps_n.trees=1500, ps_shrinkage=0.01, ps_stop.method=c("es.max") ) desc.effects(fit.es.max)

See Also

desc.effects, wgtmed

  • Maintainer: Dan McCaffrey
  • License: GPL-3
  • Last published: 2022-08-16

Useful links