calculate_estimates function

calculate_estimates

calculate_estimates

Mid-level function that helps with estimation process. Calls lower level helper functions

calculate_estimates( qoi.in, data.in, lead, number.iterations, att.treated.unit.ids, atc.treated.unit.ids, outcome.variable, unit.id.variable, confidence.level, att.sets, atc.sets, placebo.test = FALSE, lag, se.method, pooled = FALSE, parallel = FALSE, num.cores = 1 )

Arguments

  • qoi.in: String specifying qoi
  • data.in: data.frame object with the data
  • lead: integer specifying lead window
  • number.iterations: integer. specifies number of bootstrap iterations
  • att.treated.unit.ids: Integer vector specifying the treated units for the att or art
  • atc.treated.unit.ids: Integer vector specifying the "treated" units under the atc definition
  • outcome.variable: string specifying the name of the outcome variable
  • unit.id.variable: string specifying the name of the unit id variable
  • confidence.level: double. specifies confidence level for confidence interval
  • att.sets: matched.set object specifying the att or art sets
  • atc.sets: matched.set object specifying the atc sets
  • lag: integer vector specifying size of the lag.
  • se.method: string specifying which method should be used for standard error calculation
  • pooled: bool. specifies whether or not estimates should be calculated for each lead period, or pooled across all lead periods
  • parallel: bool. Specifies whether or not parallelization should be used
  • num.cores: Integer. specifies how many cores to use for parallelization

Returns

Returns PanelEstimate object.

  • Maintainer: In Song Kim
  • License: GPL (>= 3)
  • Last published: 2025-03-03

Useful links