Why are the survival curves different for the Kaplan Meier method and cox regression for the same categorical variable? I have 1 categorical variable called group (1 = treatment, 2 = placebo). If I create the survival curves with the Kaplan Meier method in SPSS I see that the survival is better for the treatment group compared to the placebo group. The survival curves are also significantly different according to the log-rank test.
When I do cox regression with the same variable (without adding other variables) the hazard ratio is significant as well and has a value below 1 (comparing treatment group to placebo group), indicating that the treatment group is associated with decreased hazard. So this is all as expected.
I can also create survival curves during the cox regression in SPSS. I can then seperate the lines for the group variable. However, these survival curves look different than the survival curves of the Kaplan Meier. How is this possible? Also the amount of vertical drops in the curve (which indicates that a patient has died) is also different between the cox regression and kaplan meier survival curves...The amount of vertical drops are somehow similar for the survival curves of the treatment group and placebo group in the cox regression...
Is the interpretation of the survival curves different for the cox regression than for the Kaplan Meier method? Is a vertical drop not a patient that died in cox regression? And how are the survival curves different for the cox regression and kaplan meier when I have the same variable and are comparing the same groups? Is this because the survival probability is calculated in another way?
I hope you can help we further and explain it in an easy way.
Thanks a lot for your help in advance!

It sounds like you have plotted the Kaplan-Meier estimate for each group separately. The Kaplan-Meier survival estimate at time t (probability of surviving until at least time t) is given by
$$
\hat{S}\left(t\right) = \prod_{i: \, t_i \leq t}\left(1 - \frac{d_i}{n_i} \right)
$$
That is to say the decrease in the survival curve is simply given by the number of people who died in the group at the ith event time, divided by the number still alive in the group before the ith event time.
For the Cox regression method, the hazard function (probability of dying in a small time interval given you survived until the start of the interval, divided by the length of the interval), is given by
$$
\lambda\left(t | X \right) = \lambda_0\left(t\right) e^{X \beta}
$$
where X is the indicator for being in the treatment group (1 if treatment, 0 if control), and $\lambda_0$ is the baseline hazard across the two groups.
So note the hazard at any given time is proportional between the two groups - it differs only by a time-independent constant $e^{X \beta}$. This is why the jump sizes have to be the same between the two groups. It also allows us to have a nice interpretation for $e^{X \beta}$ as the multiplicative increase (or decrease) in hazard due to receiving the treatment.
And the fact that the jump sizes are forced to be the same in the Cox model (which they aren't in the KM estimate), is why the survival curves look different.
(Note the survival curve is a function of the hazard, so forcing jumps in the hazard to proportional has the same effect on the survival curve).
