-
Notifications
You must be signed in to change notification settings - Fork 6
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
How the KM curve is drawn? #15
Comments
We do not provide the code for drawing KM curves as it is pretty standard code from lifelines. However, here's an overview of the process. We first use the model from each fold post training to predict the risk scores on the validation set for that fold. Then we concat the risk scores for all of the validation folds, giving us the risk scores for the entire dataset. We then use lifelines to fit a KM fitter and plot in 2 risk groups (high and low). The same package is used to perform the logrank statistical test between risk groups as well. Please let us know if something is unclear and we would be happy to help! |
Is the distinction between high and low risk groups based on the median? Also, I still have a question if it is feasible to construct a risk score for the overall dataset using the risk scores obtained from the validation set for each fold? Since the training data is different for each fold, the weights obtained should be different, right? Won't this direct integration cause some irregularities?
Thank you for your patience!
王默涵
***@***.***
…------------------ 原始邮件 ------------------
发件人: "mahmoodlab/SurvPath" ***@***.***>;
发送时间: 2024年12月17日(星期二) 凌晨5:57
***@***.***>;
***@***.******@***.***>;
主题: Re: [mahmoodlab/SurvPath] How the KM curve is drawn? (Issue #15)
We do not provide the code for drawing KM curves as it is pretty standard code from lifelines. However, here's an overview of the process. We first use the model from each fold post training to predict the risk scores on the validation set for that fold. Then we concat the risk scores for all of the validation folds, giving us the risk scores for the entire dataset. We then use lifelines to fit a KM fitter and plot in 2 risk groups (high and low). The same package is used to perform the logrank statistical test between risk groups as well.
Please let us know if something is unclear and we would be happy to help!
—
Reply to this email directly, view it on GitHub, or unsubscribe.
You are receiving this because you authored the thread.Message ID: ***@***.***>
|
您好,请问您解决了绘制KM曲线的问题了吗?能否分享一下代码呀~ |
I didn't quite understand, is this KM curve drawn with validation set data or training set? Is there any specific code for this, as the article doesn't explain this in detail. After the 5-fold cross-training, is the one with the best results chosen to draw the KM curve?
The text was updated successfully, but these errors were encountered: