linear_trends: linear_trends

View source: R/lt.R

linear_trendsR Documentation

linear_trends

Description

Compute treatment effects in model with linear trends for untreated potential outcomes

Usage

linear_trends(
  yname,
  gname,
  tname,
  idname,
  data,
  xformla = ~1,
  anticipation = 0,
  cband = TRUE,
  alp = 0.05,
  boot_type = "multiplier",
  biters = 100,
  cl = 1,
  ...
)

Arguments

yname

Name of outcome in data

gname

Name of group in data

tname

Name of time period in data

idname

Name of id in data

data

balanced panel data

xformla

Formula for which covariates to include in the model. Default is ~1.

anticipation

Number of periods that treatment is anticipated. Default is 0. This is in “periods”; e.g., code will work in time periods are equally spaced but 2 years apart. In this case, to allow for treatment anticipation of 2 year (<=> 1 period), set anticipation = 1.

cband

whether or not to compute a uniform (instead of pointwise) confidence band

alp

significance level; default is 0.05

boot_type

should be one of "multiplier" (the default) or "empirical". The multiplier bootstrap is generally much faster, but attgt_fun needs to provide an expression for the influence function (which could be challenging to figure out). If no influence function is provided, then the pte package will use the empirical bootstrap no matter what the value of this parameter.

biters

number of bootstrap iterations; default is 100

cl

number of clusters to be used when bootstrapping; default is 1

Value

pte::pte_results object


bcallaway11/ife documentation built on Sept. 15, 2023, 12:33 a.m.