作者wlsherica (Mon_tresor)
看板Statistics
標題Re: [問題] 請問R的問題
時間Tue Jun 2 19:00:48 2009
我也有同樣的問題, 以下是我的指令:
我想計算Kaplan Meier estimator, days是觀察時間, status=1是死亡event
survfit(Surv(days, status = = 1))
可是output都一直出現:
錯誤在
Survfit requires a formula or a coxph fit as the first argument
>
----
我是參照書上範例打的, 請問有高手知道問題在哪嗎??
謝謝^^
--
※ 發信站: 批踢踢實業坊(ptt.cc)
◆ From: 219.86.133.37
1F:推 alias:你還少了一些東西,以下是R的範例,資料為內建的,網址給你參考 06/02 19:51
2F:→ alias:survfit(Surv(time, status) ~ x, data=aml) 06/02 19:52
3F:→ alias:更正: 在R視窗中鍵入 help("survfit") 06/02 19:57
4F:→ wlsherica:喔非常感謝!!!我試試~~~ 06/02 20:09