pretreatments-mediation_data-method: Pretreatments in a Mediation Data Object

pretreatments,mediation_data-methodR Documentation

Pretreatments in a Mediation Data Object

Description

This is an accessor function to the @pretreatments slot in a mediation data object. It returns the entire set of observed pretreatments, in contrast to pretreatments() applied to a multimedia object, which only returns the names of the pretreatment variables.

Usage

## S4 method for signature 'mediation_data'
pretreatments(object)

Arguments

object

An object of class mediation_data.

Value

A data.frame whose rows are samples and columns different pretreatments.

Examples

exper <- demo_joy() |>
    mediation_data("PHQ", "treatment", starts_with("ASV"))
pretreatments(exper)

multimedia documentation built on Sept. 30, 2024, 9:28 a.m.