Learn R Programming

robmed (version 0.1.1)

coef.testMediation: Coefficients in (robust) mediation analysis

Description

Extract coefficients from models computed in (robust) mediation analysis.

Usage

# S3 method for testMediation
coef(object, parm = NULL, ...)

# S3 method for bootTestMediation coef(object, parm = NULL, type = c("boot", "data"), ...)

# S3 method for fitMediation coef(object, parm = NULL, ...)

Arguments

object

an object inheriting from class "testMediation" containing results from (robust) mediation analysis, or an object inheriting from class "fitMediation" containing a (robust) mediation model fit.

parm

an integer, character or logical vector specifying the coefficients to be extracted, or NULL to extract all coefficients.

type

a character string specifying whether to extract the means of the bootstrap distribution ("boot"; the default), or the coefficient estimates based on the full data set ("data").

additional arguments are currently ignored.

Value

A numeric vetor containing the requested coefficients.

See Also

testMediation, fitMediation, confint