Skip to contents

This function plots 1) the ATE as a function of the sensitivity function value when it is constant and 2) its associate 95 interval obtained via bootstrapping, if desired. The latter process can be take a few seconds to minutes.

Usage

plot_causens(
  trt_model,
  data,
  outcome,
  method,
  c1_upper = 0.5,
  c1_lower = 0,
  r = 1,
  bootstrap = TRUE
)

Arguments

trt_model

The treatment model object as a formula or fitted glm.

data

A data frame containing the variables of interest.

outcome

The name of the outcome variable.

method

The method to use for sensitivity analysis (see `causens` function).

c1_upper

The upper bound for the sensitivity function value.

c1_lower

The lower bound for the sensitivity function value.

r

The ratio between c1 and c0.

bootstrap

Bootstrap or not current estimate process and plot the estimated confidence interval.

Value

A plot of the ATE as a function of c1 values.