therneau/survival

Wrong number of individuals at "Number at risk"

Closed this issue · 1 comments

Hello developers. I have encountered some issue with the number of individuals at risk. I have data on the survival of patients for 20 years. In the original data I have some patients left alive, but table "Number at risk" shows that there is zero individuals left to be at risk.

Moreover, I get very strange numbers of n.risk after fitting survfit (they are dropping and then rising again):
[1] 50 49 48 47 46 45 44 43 42 41 40 39 38 37 36 35 34 33 32 31 30 29 28 27 26 25 24 23 22 21
[31] 20 19 18 17 16 15 14 13 12 11 10 9 8 7 6 5 4 3 2 1 51 50 49 48 47 46 45 43 42 41
[61] 40 39 38 37 36 35 34 33 32 31 30 29 28 27 26 25 24 23 22 21 20 19 18 17 16 15 14 13 12 11
[91] 10 9 8 7 6 5 4 3 2 1

Could you, please, explain me what's hapenning here?

You have shown no code and no data, and I am not clairvoyant. This might be a better issue for the r-help mailing list.