The CAUSALTRT Procedure

Getting Started: CAUSALTRT Procedure

(View the complete code for this example.)

This section illustrates some of the basic features of the CAUSALTRT procedure. This example uses data from a hypothetical nonrandomized trial.

Suppose that 486 patients in a trial are at risk for developing type 2 diabetes and are allowed to choose which of two preventive drugs they want to receive. For this study, the outcome of interest is whether a patient develops type 2 diabetes within five years. The nonrandom assignment of patients to treatment conditions does not control for confounding variables that might explain any observed difference between the treatment conditions. The hypothetical data set Drugs contains the following variables:

  • Age: age at the start of the trial

  • Bmi: body mass index at the start of the trial

  • Diabetes2: indicator for whether a patient developed type 2 diabetes, with values Yes and No

  • Drug: indicator of treatment assignment, with values Drug_A and Drug_X

  • Gender: gender

The first 10 observations in the Drugs data set are listed in Figure 33.1.

Figure 33.1: Drug Trial Data

ObsGenderAgeBmiDrugDiabetes2
1Male2922.02Drug_AYes
2Female3023.83Drug_XYes
3Female4223.64Drug_XYes
4Male4723.67Drug_ANo
5Female4222.27Drug_AYes
6Male4526.90Drug_AYes
7Female4624.06Drug_AYes
8Female4523.41Drug_AYes
9Female2824.65Drug_XNo
10Male3620.13Drug_XYes


The following statements invoke the CAUSALTRT procedure and request the estimation of the average treatment effect (ATE) by using the inverse probability weighting method with ratio adjustment (METHOD=IPWR):

proc causaltrt data=drugs method=ipwr ppsmodel;
   class Gender;
   psmodel Drug(ref='Drug_A') = Age Gender Bmi;
   model Diabetes2(ref='No') / dist = bin;
run;

The results of this analysis are shown in the following figures. In Figure 33.2, PROC CAUSALTRT displays information about the estimation method used, the outcome variable, and the treatment variable.

Figure 33.2: Model Information

The CAUSALTRT Procedure

Model Information
Data SetWORK.DRUGS
DistributionBinomial
Estimation MethodIPWR
Treatment VariableDrug
Outcome VariableDiabetes2


The METHOD= option in the PROC CAUSALTRT statement specifies the estimation method to be used. The outcome variable, Diabetes2, is specified in the MODEL statement, and the treatment variable, Drug, is specified in the PSMODEL statement.

The DIST=BIN option in the MODEL statement identifies the outcome as a binary variable, and the ref='No' option identifies No as the reference level. In the PSMODEL statement, the ref='Drug_A' option identifies Drug_A as the reference (control) condition when the treatment assignment is modeled and the ATE is estimated. The frequencies for the outcome and treatment variable categories are listed in the "Response Profile" (Figure 33.3) and "Treatment Profile" (Figure 33.4) tables, respectively.

Figure 33.3: Response Profile

Response Profile
Ordered
Value
Diabetes2Total
Frequency
1Yes287
2No199


Figure 33.4: Treatment Profile

Treatment Profile
Ordered
Value
DrugTotal
Frequency
1Drug_X149
2Drug_A337


The IPWR estimation method uses inverse probability weighting to estimate the potential outcome means and ATE. The inverse probability weights are estimated by inverting the predicted probability of receiving treatment (that is, the Drug_X condition), which is estimated from a logistic regression model that is specified in the PSMODEL statement. The probability of receiving treatment is called the propensity score, and hence the regression model fit by the PSMODEL statement is also called the propensity score model. In this example, the predictors of the propensity score model are Age, Gender, and Bmi. The PPSMODEL option in the PROC CAUSALTRT statement displays the parameter estimates for the propensity score model, as shown in Figure 33.5.

Figure 33.5: Propensity Score Model Estimates

The CAUSALTRT Procedure

Propensity Score Model Estimates
Parameter EstimateStandard
Error
Wald 95%
Confidence Limits
Wald
Chi-Square
Pr > ChiSq
Intercept -0.62261.2738-3.11931.87400.23890.6250
Age -0.08880.0170-0.1220-0.055627.4228<.0001
GenderFemale-0.21030.2055-0.61300.19241.04740.3061
GenderMale0.....
Bmi 0.14340.05170.04220.24477.71150.0055


The estimates for the potential outcome means (POM) and ATE are displayed in the "Analysis of Causal Effect" table (Figure 33.6). The ATE estimate of –0.1787 indicates that Drug_X is more effective on average than Drug_A in preventing the development of type 2 diabetes. The ATE is significantly different from 0 at the 0.05 -level, as indicated by the 95% confidence interval (–0.2771, –0.0803) or the p-value (0.0004).

Figure 33.6: IPWR Potential Outcome Means and ATE Estimates

The CAUSALTRT Procedure

Analysis of Causal Effect
ParameterTreatment LevelEstimateRobust
Std Err
Wald 95%
Confidence Limits
ZPr > |Z|
POMDrug_X0.46810.04310.38350.552610.85<.0001
POMDrug_A0.64680.02650.59480.698824.38<.0001
ATE -0.17870.0502-0.2771-0.08031-3.560.0004


The ATE of Drug_X compared to Drug_A can also be estimated by using augmented inverse probability weights (AIPW). In addition to a propensity score model, the AIPW estimation method incorporates a model for the outcome variable, Diabetes2, into the estimation of the potential outcome means and ATE. The AIPW estimation method is doubly robust and provides unbiased estimates for the ATE even if one of the outcome or treatment models is misspecified.

The following statements invoke the CAUSALTRT procedure and use the AIPW estimation method to estimate the ATE:

proc causaltrt data=drugs method=aipw;
   class Gender;
   psmodel Drug(ref='Drug_A') = Age Gender Bmi;
   model Diabetes2(ref='No') = Age Gender Bmi / dist = bin;
run;

For this example, the same set of effects is specified in both the MODEL and PSMODEL statements, but in general this need not be the case. The use of the AIPW estimation method for this PROC CAUSALTRT step is reflected in the "Model Information" table (Figure 33.7).

Figure 33.7: Model Information

The CAUSALTRT Procedure

Model Information
Data SetWORK.DRUGS
DistributionBinomial
Link FunctionLogit
Estimation MethodAIPW
Treatment VariableDrug
Outcome VariableDiabetes2


As shown in Figure 33.8, the AIPW estimate for the ATE is –0.1709, which is similar to the IPWR estimate of –0.1787. Moreover, the AIPW standard error estimate for ATE is slightly smaller than that of the IPWR. The AIPW 95% confidence interval for ATE is also slightly narrower than that of the IPWR.

Figure 33.8: AIPW Potential Outcome Means and ATE Estimates

The CAUSALTRT Procedure

Analysis of Causal Effect
ParameterTreatment LevelEstimateRobust
Std Err
Wald 95%
Confidence Limits
ZPr > |Z|
POMDrug_X0.47820.04220.39540.560911.32<.0001
POMDrug_A0.64910.02670.59680.701324.33<.0001
ATE -0.17090.0495-0.2679-0.07390-3.450.0006