Learn R Programming

gfoRmulaICE (version 1.1.1)

static: Static

Description

This function specifies the static intervention, either treat with a constant value or never treat, on the treatment variable in data.

Usage

static(value, data)

Value

a vector containing the intervened values of the same size as the number of rows in data.

Arguments

value

a number specifying the intervention value. 0 for never treat.

data

a data frame containing the observed data.

Examples

Run this code
data <- gfoRmulaICE::compData
always_treat <- static(value = 1, data = data)

Run the code above in your browser using DataLab