lasso_cox.r lasso_cox 模型优化分析

lasso_cox.r lasso_cox 模型优化分析

使用说明:

Rscript $scriptdir/lasso_cox.r -h 
usage: /work/my_stad_immu/scripts/lasso_cox.r [-h] -i data -t time -e event -v
                                              variate [variate ...] [-s seed]
                                              [-l lambda] [-P predict.time]
                                              [-o outdir] [-p prefix]

lasso cox regression analysis

optional arguments:
  -h, --help            show this help message and exit
  -i data, --data data  input data file path[required]
  -t time, --time time  set suvival time column name [required]
  -e event, --event event
                        set event column name [required]
  -v variate [variate ...], --variate variate [variate ...]
                        variate for cox analysis [required]
  -s seed, --seed seed  set random seed [default 2021]
  -l lambda, --lambda lambda
                        set lambda cut off [default NULL]
  -P predict.time, --predict.time predict.time
                        Time point of the ROC curve to select cutoff [default
                        365 1095 1825]
  -o outdir, --outdir outdir
                        output file directory [default cwd]
  -p prefix, --prefix prefix
                        out file name prefix [default lasso_cox]


使用举例:

Rscript $scriptdir/lasso_cox.r -i imm.unicox.metadata-exp.tsv -e EVENT -t TIME \

  -v SYT12 CDH2 GPNMB TMIGD3 LINC01094 SLC22A20P IGHV4-61 IGHV2-5 SERPINA5 MS4A4A FAM83A IGLV3-9 STARD3    -o lasso


参数说明:

-i 输入生存数据,与基因表达文件 


barcode TIME EVENT FGR CD38 ITGAL CX3CL1 CEACAM21 MATK CD79B MMP25
TCGA-B7-A5TK-01A-12R-A36D-31 288 0 16.34408 86.86772 40.26903 603.0132 1.868536 2.28342 3.453198 13.72829
TCGA-BR-7959-01A-11R-2343-13 1010 0 11.96739 15.79451 7.358566 26.91353 2.571917 0.864116 1.879957 3.451148
TCGA-IN-8462-01A-11R-2343-13 572 0 5.350846 3.111342 3.769125 20.22238 0.610839 0.519776 2.822192 1.106563
TCGA-CG-4443-01A-01R-1157-13 912 0 1.53802 0.862955 2.37351 19.04097 1.092127 0.760348 1.926592 0.878735
TCGA-KB-A93J-01A-11R-A39E-31 1124 0 15.24016 13.3047 38.08591 14.15295 3.483559 3.192951 3.651742 10.43186
TCGA-HU-A4H3-01A-21R-A251-31 882 0 6.261761 2.675173 7.025886 4.050271 0.584159 1.039336 1.979214 2.312993
TCGA-RD-A8MV-01A-11R-A36D-31 3720 0 27.07415 20.15885 34.91309 34.71821 4.113112 2.615557 16.51946 17.72674
TCGA-VQ-A91X-01A-12R-A414-31 289 1 1.062341 0.752018 2.380513 4.415815 0.518142 0.212197 1.239203 0.582114
TCGA-D7-8575-01A-11R-2343-13 554 1 42.12665 6.86405 26.1565 52.41987 2.853084 9.824916 4.138801 5.030352
TCGA-BR-8485-01A-11R-2402-13 280 0 25.90812 12.82056 30.65228 16.49019 3.033067 3.498083 7.771042 5.309015
TCGA-D7-A748-01A-12R-A32D-31 132 1 24.63917 5.58798 11.61812 11.11332 3.543125 2.443914 3.501343 2.338182
TCGA-VQ-A91Z-01A-11R-A414-31 1690 0 15.30907 0.282728 1.902445 16.6445 0.652479 0.220248 0.109621 0.911825
TCGA-RD-A7C1-01A-11R-A32D-31 507 1 22.84513 9.611072 14.94431 5.857966 3.243776 1.993854 4.617576 6.656729
TCGA-CG-4465-01A-01R-1157-13 274 1 11.01848 3.2437 16.75908 3.962907 2.761824 1.267627 2.155049 1.858322
TCGA-BR-8384-01A-21R-2402-13 113 0 15.50016 6.808935 29.87046 25.81994 3.846517 3.277526 7.957455 4.519639
TCGA-HU-A4G8-01A-11R-A251-31 690 0 7.527245 5.605723 23.17087 5.796453 2.2814 1.983006 16.13655 9.410047
TCGA-BR-8382-01A-11R-2402-13 762 1 19.62473 5.774798 12.34635 71.23714 3.814144 2.832469 5.00467 8.386162
TCGA-HU-A4G9-01A-11R-A24K-31 736 0 2.078504 0.446876 1.363617 1.121539 0.113845 0.528398 0.771445 2.704629
TCGA-BR-8289-01A-11R-2343-13 81 1 4.310812 2.515848 5.747723 7.29023 1.090392 5.493223 4.324129 2.328028
TCGA-BR-A44U-01A-11R-A36D-31 422 1 3.826054 0.742352 2.135874 5.699938 0.039517 0.311807 0.51122 0.902007
TCGA-HF-A5NB-01A-11R-A31P-31 928 0 3.69683 1.088005 7.617025 1.757371 1.400757 1.625366 0.769616 1.490192
TCGA-R5-A7ZE-01B-11R-A354-31 554 1 1.538295 0.947096 0.777948 3.410414 0.804264 0.138651 0.403436 6.658023
TCGA-FP-7829-01A-11R-2055-13 594 0 12.28237 0.781318 5.613579 8.832561 2.554426 3.793948 2.274555 2.120219
TCGA-D7-6522-01A-11R-1802-13 566 0 32.70644 13.9756 56.46687 35.31465 12.53402 10.22565 119.3415 10.9099
TCGA-CD-A487-01A-21R-A24K-31 374 0 13.55841 2.039681 2.889515 15.1464 1.182142 0.696399 1.470464 4.257127
TCGA-HU-A4GF-01A-11R-A24K-31 785 0 9.987734 16.81528 12.3633 27.06354 1.301881 0.993662 2.111913 5.013326
TCGA-R5-A7O7-01A-11R-A33Y-31 1389 0 4.999295 3.350161 7.87305 11.13146 1.642943 1.698416 5.451512 4.626745


结果展示:



attachments-2021-06-4DAtjEpv60d59b928292a.png


attachments-2021-06-13vJhQJT60d59ba19088a.png

Construction of a predictive model and the CIHI. (A, B) The LASSO Cox regression model was constructed from 11 signature genes, and the tuning parameter (λ) was calculated based on the partial likelihood deviance with ten-fold cross validation.


参考文献:


We applied the Cox regression model with LASSO based on the R package “glmnet” to construct an optimal  gene‐associated prognostic model。

The Risk score was calculated with the following formula: The  risk score=


attachments-2021-06-PCuozLir60d59d023b1ad.png

, where Expri represents the expression level of gene i and coefi represents the regression coefficient of gene i in the signature.We grouped all patients into low- or high-risk groups according to the median value of IGPM‐based risk signature and performed survival analysis with Kaplan-Meier method. The logrank test was used to compare the difference in the survival status between the high‐ and low‐risk groups.


attachments-2021-07-pixMJ7Ct60dd1ab017657.png

attachments-2021-07-kmtIVrSl60dd1ace16f74.png


To reflect the prediction ability of the IGPM‐based risk signature, we generated the time-dependent receiver operating characteristic curve (ROC) and calculated the area under the curve (AUC)  (R package “survivalROC” ) for 1-year, 3-year, and 5-year overall survival (OS). The Kaplan-Meier, log‐rank, ROC curve, and calibration analyses were all performed and visualized by the “survivalROC”, “rms”, “survival”, and “survminer” packages.


attachments-2021-07-S5ZQDzHc60dd1a799c093.png

Tibshirani R (1997) The lasso method for variable selection in the Cox model. Stat Med 16, 385–395.




References

Simon, Noah, Jerome Friedman, Trevor Hastie, and Robert Tibshirani. 2011. “Regularization Paths for Cox’s Proportional Hazards Model via Coordinate Descent.” Journal of Statistical Software, Articles 39 (5): 1–13. https://doi.org/10.18637/jss.v039.i05.

Therneau, Terry M., and Patricia M. Grambsch. 2000. Modeling survival data: extending the Cox model. Springer.

  • 发表于 2021-06-25 17:00
  • 阅读 ( 51 )
  • 分类:临床医学

0 条评论

请先 登录 后评论
omicsgene
omicsgene

生物信息

462 篇文章

作家榜 »

  1. omicsgene 462 文章
  2. 安生水 226 文章
  3. Daitoue 167 文章
  4. 生物女学霸 120 文章
  5. CORNERSTONE 72 文章
  6. 红橙子 65 文章
  7. 生信老顽童 48 文章
  8. landy 37 文章