Eavis / web_app

0 stars 0 forks source link

try survival analysis #25

Open Eavis opened 7 years ago

Eavis commented 7 years ago

Install minianaconda export PATH=/Users/tianyulan/miniconda3/bin:$PATH source ~/.zshrc

Eavis commented 7 years ago

create a new Python 3.4 virtual environment called survivalenv including most of the packages conda install -n survivalenv python=3.6 --file requirements_conda

Eavis commented 7 years ago

https://help.github.com/articles/merging-an-upstream-repository-into-your-fork/

Eavis commented 7 years ago

https://help.github.com/articles/adding-a-file-to-a-repository-using-the-command-line/

Eavis commented 7 years ago

http://blog.applied.ai/survival-analysis-part2/

Eavis commented 7 years ago

Use python to access mysql

https://www.tutorialspoint.com/python/python_database_access.htm

Eavis commented 7 years ago

NAN value problem in python read mysql https://stackoverflow.com/questions/37796916/pandas-read-sql-integer-became-float

Eavis commented 7 years ago

age_at_initial_pathologic_diagnosis_Clinical 0.5564 1.7444 0.0533 10.4463 0.0000 0.4520 0.6608 * gender-Is-male_Clinical 0.1986 1.2197 0.0867 2.2898 0.0220 0.0286 0.3686 race-Is-white_Clinical 5.3605 212.8213 nan nan nan nan nan
race-Is-black or african american_Clinical 5.1922 179.8725 nan nan nan nan nan
race-Is-asian_Clinical 4.6535 104.9514 nan nan nan nan nan
histological_type-Is-oligoastrocytoma_Clinical -0.8852 0.4126 nan nan nan nan nan
histological_type-Is-astrocytoma_Clinical -0.3710 0.6900 nan nan nan nan nan
histological_type-Is-oligodendroglioma_Clinical -1.1381 0.3204 nan nan nan nan nan
histological_type-Is-glioblastoma multiforme (g... 1.1553 3.1750 nan nan nan nan nan
histological_type-Is-treated primary gbm_Clinical 0.6063 1.8336 nan nan nan nan nan
histological_type-Is-untreated primary (de novo... 0.8634 2.3712 nan nan nan nan nan
radiation_therapy-Is-yes_Clinical -0.4662 0.6274 0.1205 -3.8683 0.0001 -0.7024 -0.2299

Signif. codes: 0 '' 0.001 '' 0.01 '' 0.05 '.' 0.1 ' ' 1

Concordance = 0.810

Eavis commented 7 years ago

n=1035, number of events=584

                                           coef  exp(coef)  se(coef)       z      p  lower 0.95  upper 0.95     

age_at_initial_pathologic_diagnosis_Clinical 0.8504 2.3406 0.0486 17.4984 0.0000 0.7551 0.9457 ***

Signif. codes: 0 '' 0.001 '' 0.01 '' 0.05 '.' 0.1 ' ' 1

Concordance = 0.744 n=1035, number of events=584

                      coef  exp(coef)  se(coef)      z      p  lower 0.95  upper 0.95    

gender-Is-male_Clinical 0.2372 1.2677 0.0853 2.7806 0.0054 0.0700 0.4044 **

Signif. codes: 0 '' 0.001 '' 0.01 '' 0.05 '.' 0.1 ' ' 1

Concordance = 0.530 n=1035, number of events=584

                     coef  exp(coef)  se(coef)      z      p  lower 0.95  upper 0.95   

race-Is-white_Clinical 0.0378 1.0385 0.1553 0.2435 0.8076 -0.2667 0.3423

Signif. codes: 0 '' 0.001 '' 0.01 '' 0.05 '.' 0.1 ' ' 1

Concordance = 0.501 n=1035, number of events=584

                                         coef  exp(coef)  se(coef)      z      p  lower 0.95  upper 0.95   

race-Is-black or african american_Clinical 0.0740 1.0768 0.1679 0.4408 0.6593 -0.2551 0.4032

Signif. codes: 0 '' 0.001 '' 0.01 '' 0.05 '.' 0.1 ' ' 1

Concordance = 0.503 n=1035, number of events=584

                      coef  exp(coef)  se(coef)       z      p  lower 0.95  upper 0.95   

race-Is-asian_Clinical -0.4718 0.6239 0.3804 -1.2404 0.2148 -1.2175 0.2739

Signif. codes: 0 '' 0.001 '' 0.01 '' 0.05 '.' 0.1 ' ' 1

Concordance = 0.505 n=1035, number of events=584

                                              coef  exp(coef)  se(coef)       z      p  lower 0.95  upper 0.95     

histological_type-Is-oligoastrocytoma_Clinical -1.3534 0.2583 0.2007 -6.7434 0.0000 -1.7469 -0.9600 ***

Signif. codes: 0 '' 0.001 '' 0.01 '' 0.05 '.' 0.1 ' ' 1

Concordance = 0.561 n=1035, number of events=584

                                         coef  exp(coef)  se(coef)       z      p  lower 0.95  upper 0.95     

histological_type-Is-astrocytoma_Clinical -0.9172 0.3996 0.1407 -6.5182 0.0000 -1.1930 -0.6413 ***

Signif. codes: 0 '' 0.001 '' 0.01 '' 0.05 '.' 0.1 ' ' 1

Concordance = 0.563 n=1035, number of events=584

                                               coef  exp(coef)  se(coef)       z      p  lower 0.95  upper 0.95     

histological_type-Is-oligodendroglioma_Clinical -1.4418 0.2365 0.1558 -9.2566 0.0000 -1.7471 -1.1364 ***

Signif. codes: 0 '' 0.001 '' 0.01 '' 0.05 '.' 0.1 ' ' 1

Concordance = 0.592 n=1035, number of events=584

                                                 coef  exp(coef)  se(coef)      z      p  lower 0.95  upper 0.95   

histological_type-Is-glioblastoma multiforme (g... 0.5839 1.7931 0.2467 2.3666 0.0180 0.1002 1.0676 *

Signif. codes: 0 '' 0.001 '' 0.01 '' 0.05 '.' 0.1 ' ' 1

Concordance = 0.508 n=1035, number of events=584

                                                coef  exp(coef)  se(coef)      z      p  lower 0.95  upper 0.95   

histological_type-Is-treated primary gbm_Clinical 0.2109 1.2348 0.2335 0.9033 0.3664 -0.2469 0.6688

Signif. codes: 0 '' 0.001 '' 0.01 '' 0.05 '.' 0.1 ' ' 1

Concordance = 0.498 n=1035, number of events=584

                                                 coef  exp(coef)  se(coef)       z      p  lower 0.95  upper 0.95     

histological_type-Is-untreated primary (de novo... 1.7223 5.5976 0.0961 17.9132 0.0000 1.5339 1.9108 ***

Signif. codes: 0 '' 0.001 '' 0.01 '' 0.05 '.' 0.1 ' ' 1

Concordance = 0.710 n=1035, number of events=584

                                coef  exp(coef)  se(coef)      z      p  lower 0.95  upper 0.95     

radiation_therapy-Is-yes_Clinical 0.4247 1.5292 0.1102 3.8544 0.0001 0.2087 0.6407 ***

Signif. codes: 0 '' 0.001 '' 0.01 '' 0.05 '.' 0.1 ' ' 1

Concordance = 0.498 tianyulan@tianyulan-VirtualBox:/localdata/ActiveLearning/web_app/python$