Learn R Programming

MatchIt (version 1.0-1)

exactmatch: Exact matching

Description

exactmatch is a sub-function of matchit that does exact matching on the set of covariates.

Usage

exactmatch <- exactmatch(formula, data, counter=TRUE)

Arguments

formula
(required). Takes the form of T ~ X1 + X2, where T is a binary treatment indicator and X1 and X2 are the pre-treatment covariates, and T, X1, and X2 are contained
data
(required). Data frame containing the variables called in the formula. The dataframe should not include variables with the names psclass, psweights, or pscore, as these are expressly reserved in the o
counter
Whether to display counter indicating the progress of the matching (default=TRUE).

Value

  • psclassSubclass index in an ordinal scale from 1 to the number of subclasses. Unmatched units have subclass=0. With exact matching, these subclasses are defined by the categories of the variables in formula.

Details

This sub-function is called automatically by the matchit command when exact=TRUE is chosen, meaning exact matching on all covariates in the assignment model. It creates subclasses defined by the values of the covariates, where each subclass must contain some treated and some control units. Units with no exact matches in the other treatment group are discarded. This function is called directly by matchit and does not generally need to be called directly by users; these details are included for advanced users.

See Also

Please use help.matchit to access the matchit reference manual. The complete document is available online at http://gking.harvard.edu/matchit.