Assess Balance of Covariates after Propensity Score as Covariate Adjustment: SAS® macro Development and Application Open Access

Xi, Yizhao (Spring 2018)

Permanent URL:


Propensity score (PS) is a method used to reduce selection bias or confounding effects in observational studies, and it is defined as the conditional probability of treatment assignment given observed baseline covariates. Covariate adjustment using propensity score is one of the popular method applied in public health studies. It involves regression adjustment where outcome is regressed on a treatment indicator and on estimated propensity score. Whenever a covariate adjustment is performed, the balance between two groups should be evaluated. Weighted standardized differences have been introduced to assess the quality of balancing between treated and untreated subjects after propensity score adjustment. Imbalances in the regression adjustment should be adjusted for further study when analyzing outcomes.


However, there are few goodness-of-fit tests for this method in practical application due to the lack of a user-friendly statistical tool or software packages. In this study, a SAS® macro is developed for performing the balance diagnosis using weighted standardized difference with PS as covariate adjustment, and compared that with standardized difference without PS as covariate adjustment. A list of covariates for both categorical and continuous baseline covariates will be analyzed at one time. The macro will create two RTF files by ODS style, and one is a summary table and the other one is a graph that display the Display the covariate balance improvement after PS adjustment by the weighted standardized difference from the standardized difference before PS adjustment. Additionally, a case study was utilized to illustrate the application of the SAS® macro and summary all the findings and reports. The results indicate that the weighted standardized difference is a feasible and practical measurement to assess the balance of covariate adjustment using propensity score. With this SAS® macro development, covariate adjustment using propensity score can be more easily applied in practice.

Table of Contents

Table of Contents


1. Introduction. 1

2. Method. 3

3. SAS macro. 5

       3.1 Standardized difference calculation. 5

       3.2 Weighted standardized difference calculation. 5

              3.2.1 Categorical covariates. 5

              3.2.2 Numeric covariates. 7

       3.3 Parameter interpretation. 7

4. Case Study. 9

      4.1 Background. 9

      4.2 Data source. 9

      4.3 Statistical Analysis. 10

      4.4 Results. 11

5. Discussion. 12

6. Reference. 14

7. Tables and Figure. 16

8. Appendix. 32


About this Master's Thesis

Rights statement
  • Permission granted by the author to include this thesis or dissertation in this repository. All rights reserved by the author. Please contact the author for information regarding the reproduction and use of this thesis or dissertation.
  • English
Research Field
Committee Chair / Thesis Advisor
Committee Members
Partnering Agencies
Last modified

Primary PDF

Supplemental Files