dfl_decompose_bootstrap {ddecompose}R Documentation

Bootstrapping the DFL reweighting decomposition

Description

The function resamples observations and restimates the DFL decomposition with the new sample.

Usage

dfl_decompose_bootstrap(
  formula,
  dep_var,
  data_used,
  weights,
  group_variable,
  reference_group,
  estimate_statistics,
  statistics,
  probs,
  custom_statistic_function,
  right_to_left,
  trimming,
  trimming_threshold,
  ...
)

Arguments

formula

formula object

dep_var

dependent variable

data_used

data.frame with data used for estimation

weights

weights variable

group_variable

group variable

reference_group

reference_group to be reweighted

estimate_statistics

boolean: if TRUE (default), then distributional statistics are estimated and the decomposition is performed. If FALSE, the function only returns the fitted inverse propensity weights.

statistics

a character vector that defines the distributional statistics for which the decomposition is performed.

probs

a vector of length 1 or more with the probabilities of the quantiles to be estimated.

custom_statistic_function

a function estimating a custom distributional statistic that will be decomposed.

right_to_left

determines the direction of a sequential decomposition.

trimming

boolean: If TRUE, observations with dominant reweighting factor values are trimmed according to rule of Huber, Lechner, and Wunsch (2013).

trimming_threshold

numeric: threshold defining the maximal accepted relative weight of the reweighting factor value (i.e., inverse probability weight) of a single observation. If NULL, the threshold is set to sqrt(N)/N, where N is the number of observations in the reference group.

...

other parameters passed to the function estimating the conditional probabilities.


[Package ddecompose version 1.0.0 Index]