The PSMATCH Procedure

OUTPUT Statement

  • OUTPUT OUT <(OBS=obs-value)>=SAS-data-set <keyword=name <keyword=name …>> ;

The OUTPUT statement specifies the output data set and variables. You must specify the following option:

OUT <(OBS=obs-value)>=SAS-data-set

names the output data set. The data set also includes the results of matching if you provide the MATCH statement. You can specify one of the following values for obs-value:

OBS=ALL

requests that the output data set contain all observations.

OBS=REGION

requests that the output data set contain only observations in the specified support region.

OBS=MATCH

requests that the output data set contain only the matched treated units and control units. This option applies only if you specify the MATCH statement.

By default, OBS=ALL. The OBS= suboption is ignored if you specify the EWEIGHT statement.

Table 5 summarizes the keywords that are used to create and name the output variables.

Table 5: OUTPUT Statement Keywords

Keyword Description
LPS Specifies the variable that provides the logit of the propensity score
MATCHID Specifies the variable that provides identification numbers for the matched units
PS Specifies the variable that provides the propensity score
STRATA Specifies the variable that numbers the strata
WEIGHT Specifies the weight variable


LPS=name

creates and names the variable that provides the logit of the propensity score. This suboption is ignored if you specify the EWEIGHT statement.

MATCHID=name

creates and names the variable that provides identification numbers for the matched treated and control units. This suboption applies only if you specify the MATCH statement.

PS=name

creates and names the variable that provides the propensity score. This suboption is ignored if you specify the EWEIGHT statement.

If you omit this option and the PS= option in the PSDATA statement, then the variable that provides the propensity score is automatically created using name=_PS_.

STRATA=name

creates and names the variable that numbers the strata. This suboption applies only if you specify the STRATA statement.

If you omit this suboption but specify the STRATA statement, then the variable that numbers the strata is automatically created using name=_STRATA_.

WEIGHT=name

creates and names the weight variable. The output weight variable depends on the specified statements:

  • If you specify an EWEIGHT statement, the weight variable contains weights as specified by the WEIGHT= option in the EWEIGHT statement.

  • If you specify a MATCH statement, the weight variable contains weights of matched observations as specified by the WEIGHT= option in the MATCH statement.

  • If you specify a PSWEIGHT statement, the weight variable contains weights of observations as specified by the WEIGHT= option in the PSWEIGHT statement.

This option is ignored if you specify a STRATA statement.

Last updated: December 09, 2022