View source: R/common_support.R
common_support2 | R Documentation |
Establishes the Common Support between two groups of individuals, based on the (empirical) joint distribution of some characteristics (variables).
common_support2(data, treatment, variables)
data |
data frame |
treatment |
column name of the binary variable |
variables |
character vector of the variables' names, for which the common support has to be established |
a data frame with all the combinations of the modalities of the variables considered. In addition two columns: common_support
(logical, TRUE if in the common support), strata
(identifier of a unique combination of the modalities of the variables)
See common_support_strata2
, which uses this function and then joins with the original data.
data(invented_wages)
common_support2(invented_wages, treatment = "gender",
variables = c("sector", "education"))
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.