Suppose I have a survival data with the variables `time`

: follow up time, `event`

: event indicator(1 or 0) with 1 as an event and 0 as censored, `treatment`

: treatment group (0 or 1) and covariates `X1`

, `X2`

, `X3`

AND `X4`

.

First, I fit a logistic regression model to obtain the propensity scores. The outcome of logistic regression model is `treament`

and `X1`

, `X2`

, `X3`

AND `X4`

are the predictors and obtain the propensity scores `ps`

for each observations. Then, using inverse probability weighting, the weights `wt`

are obtained as

`treatment/ps + (1-treatment)/(1-ps).`

Now, I want to fit a Cox proportional hazards regression model with these weights as follows:

`model1 <- coxph(Surv(time,event) ~ treatment + X1 + X2 + X3 + X4, weights=wt)`

.

Is model1 same as $\lambda(t|treatment,X_1,X_2,X_3,X_4)=wt*\lambda_0(t)* e^{\gamma *treatment+\beta_1*X_1+\beta_2*X_2+\beta_3*X_3+\beta_4*X_4}$ where $\lambda_0(t)$ is the baseline hazard function? What is the interpretation of adding these weights? Am I fitting weighted Cox proportional hazards regression model?

## Best Answer

No, using the weights gives you a weighted estimator rather than a weighted model. The model is still $$\lambda(t,z)=\lambda_0(t)e^{z\beta}$$ but instead of estimating it by maximising the log partial likelihood you estimate it by maximising a weighted log partial likelihood. The contribution of observation $i$ to the log partial likelihood is multiplied by the weight $w_i$.

The resulting estimates of $\beta$ and $\lambda$ are the same as if you had $w_i$ identical copies of observation $i$ (except that $w_i$ doesn't have to be an integer), though the standard errors are not the same as if you had multiple identical copies.