Skip to main content
deleted 2573 characters in body
Source Link
Zizogolu
  • 2.2k
  • 1
  • 14
  • 46
         Survival days  MTHFD1  SH3PXD2A    CAV1    ACTB    COL5A2  CDKN2C  BAG3    RALA    DST STEAP1  FZD1    IGFBP2  RBP1
GSM482796   1450    -0.538  0.261   0.368   0.671   0.194   -0.43   -0.179  0.551   -0.117  0.18    -0.527  -0.703  -0.0586
GSM482797   936 -0.209  0.097   -0.9    -0.307  0.0873  -0.516  -0.211  0.089   -0.0729 -0.0546 -0.132  -0.481  0.0215
GSM482798   936 -0.487  0.0853  -0.518  0.162   0.0326  -0.264  -0.0957 0.237   -0.0855 -0.243  -0.137  0.0581  0.11
GSM482799   2060    -0.355  0.0949  -0.198  0.232   0.0123  -0.506  0.0424  0.0626  0.128   0.0602  -0.538  -0.0969 0.277
GSM482800   2574    -0.547  0.0836  -0.81   -0.211  0.0928  -0.536  -0.301  0.126   -0.327  0.129   -0.251  0.536   0.02
GSM482801   2313    -0.484  -0.333  -1.13   0.312   -0.0508 -0.848  -0.0893 0.164   -0.15   -0.2    -0.85   0.0732  0.12
GSM482802   176 -0.343  0.194   1.29    0.436   0.221   -0.717  0.0727  0.65    1.29    0.857   0.00985 -0.384  0.289
GSM482803   NA  -0.623  0.176   -0.581  0.341   -0.0391 -0.446  -0.00736    -0.0541 -0.157  -0.197  -0.349  0.304   0.26
GSM482804   1327    -0.381  0.0195  -0.939  0.024   0.0151  -0.513  0.832   -0.055  0.0195  0.431   -0.673  -0.521  0.0575
GSM482805   1575    -0.167  0.0854  -0.411  0.0854  0.105   -0.296  0.101   0.31    0.798   -0.12   -0.152  0.119   0.142
GSM482806   687 -0.439  -0.0619 -1.06   0.0728  0.0771  -0.155  -0.232  0.164   -0.0181 0.196   0.449   0.748   -0.0259
GSM482807   736 -0.744  -0.191  -1.37   0.148   0.0684  -0.698  -0.292  0.187   -0.0628 -0.396  -0.598  -0.488  0.0977
GSM482808   816 -0.607  -0.194  -0.358  0.0134  0.159   -0.26   0.0238  -0.374  0.555   0.274   0.358   -0.0953 0.171
GSM482809   253 -0.354  0.121   -1.22   0.402   -0.0781 -0.699  -0.159  0.345   -0.0888 0.0523  -0.888  -0.759  0.0681
GSM482810   477 -0.607  -0.201  -1.05   0.551   -0.0554 -0.655  -0.148  -0.0741 -0.78   -0.31   -0.716  -0.154  0.0134
GSM482811   1035    -0.516  0.346   -0.62   0.0466  0.0884  -0.244  0.107   0.101   0.807   0.473   0.291   -0.417  0.0251
GSM482812   1984    -0.281  -0.0653 -0.917  0.255   -0.0167 -0.683  -0.0696 0.559   -0.175  -0.253  -0.458  -0.536  0.0461
GSM482813   2045    -0.42   0.0355  -0.792  0.513   0.158   -0.245  0.514   0.184   -0.211  -0.364  -0.573  0.183   0.049
> head(km)
    samples time        gene
1 GSM482796 1450 -0.11931980
2 GSM482797  936 -0.12209097
3 GSM482798  936 -0.10390257
4 GSM482799 2060 -0.07646939
5 GSM482800 2574 -0.16656837
6 GSM482801 2313 -0.12507939
>
> head(km)
     Sample Time        Gene Status
1 GSM482853   41  0.05649159    Low
2 GSM482857   41 -0.07667345    Low
3 GSM482866   54  0.10231150    Low
4 GSM482830   61 -0.05980938    Low
5 GSM482861   77  0.01231947    Low
6 GSM482818   78  0.21372177    Low
>

 fit <- survfit(Surv(Time, Status) ~ Gene, data = km)


> ggsurvplot(fit, data = km)
Error in data.frame(..., check.names = FALSE) : 
  arguments imply differing number of rows: 70, 0, 140
         Survival days  MTHFD1  SH3PXD2A    CAV1    ACTB    COL5A2  CDKN2C  BAG3    RALA    DST STEAP1  FZD1    IGFBP2  RBP1
GSM482796   1450    -0.538  0.261   0.368   0.671   0.194   -0.43   -0.179  0.551   -0.117  0.18    -0.527  -0.703  -0.0586
GSM482797   936 -0.209  0.097   -0.9    -0.307  0.0873  -0.516  -0.211  0.089   -0.0729 -0.0546 -0.132  -0.481  0.0215
GSM482798   936 -0.487  0.0853  -0.518  0.162   0.0326  -0.264  -0.0957 0.237   -0.0855 -0.243  -0.137  0.0581  0.11
GSM482799   2060    -0.355  0.0949  -0.198  0.232   0.0123  -0.506  0.0424  0.0626  0.128   0.0602  -0.538  -0.0969 0.277
GSM482800   2574    -0.547  0.0836  -0.81   -0.211  0.0928  -0.536  -0.301  0.126   -0.327  0.129   -0.251  0.536   0.02
GSM482801   2313    -0.484  -0.333  -1.13   0.312   -0.0508 -0.848  -0.0893 0.164   -0.15   -0.2    -0.85   0.0732  0.12
GSM482802   176 -0.343  0.194   1.29    0.436   0.221   -0.717  0.0727  0.65    1.29    0.857   0.00985 -0.384  0.289
GSM482803   NA  -0.623  0.176   -0.581  0.341   -0.0391 -0.446  -0.00736    -0.0541 -0.157  -0.197  -0.349  0.304   0.26
GSM482804   1327    -0.381  0.0195  -0.939  0.024   0.0151  -0.513  0.832   -0.055  0.0195  0.431   -0.673  -0.521  0.0575
GSM482805   1575    -0.167  0.0854  -0.411  0.0854  0.105   -0.296  0.101   0.31    0.798   -0.12   -0.152  0.119   0.142
GSM482806   687 -0.439  -0.0619 -1.06   0.0728  0.0771  -0.155  -0.232  0.164   -0.0181 0.196   0.449   0.748   -0.0259
GSM482807   736 -0.744  -0.191  -1.37   0.148   0.0684  -0.698  -0.292  0.187   -0.0628 -0.396  -0.598  -0.488  0.0977
GSM482808   816 -0.607  -0.194  -0.358  0.0134  0.159   -0.26   0.0238  -0.374  0.555   0.274   0.358   -0.0953 0.171
GSM482809   253 -0.354  0.121   -1.22   0.402   -0.0781 -0.699  -0.159  0.345   -0.0888 0.0523  -0.888  -0.759  0.0681
GSM482810   477 -0.607  -0.201  -1.05   0.551   -0.0554 -0.655  -0.148  -0.0741 -0.78   -0.31   -0.716  -0.154  0.0134
GSM482811   1035    -0.516  0.346   -0.62   0.0466  0.0884  -0.244  0.107   0.101   0.807   0.473   0.291   -0.417  0.0251
GSM482812   1984    -0.281  -0.0653 -0.917  0.255   -0.0167 -0.683  -0.0696 0.559   -0.175  -0.253  -0.458  -0.536  0.0461
GSM482813   2045    -0.42   0.0355  -0.792  0.513   0.158   -0.245  0.514   0.184   -0.211  -0.364  -0.573  0.183   0.049
> head(km)
    samples time        gene
1 GSM482796 1450 -0.11931980
2 GSM482797  936 -0.12209097
3 GSM482798  936 -0.10390257
4 GSM482799 2060 -0.07646939
5 GSM482800 2574 -0.16656837
6 GSM482801 2313 -0.12507939
>
> head(km)
     Sample Time        Gene Status
1 GSM482853   41  0.05649159    Low
2 GSM482857   41 -0.07667345    Low
3 GSM482866   54  0.10231150    Low
4 GSM482830   61 -0.05980938    Low
5 GSM482861   77  0.01231947    Low
6 GSM482818   78  0.21372177    Low
>

 fit <- survfit(Surv(Time, Status) ~ Gene, data = km)


> ggsurvplot(fit, data = km)
Error in data.frame(..., check.names = FALSE) : 
  arguments imply differing number of rows: 70, 0, 140
>
 fit <- survfit(Surv(Time, Status) ~ Gene, data = km)


> ggsurvplot(fit, data = km)
Error in data.frame(..., check.names = FALSE) : 
  arguments imply differing number of rows: 70, 0, 140
added 2 characters in body; edited title
Source Link
Zizogolu
  • 2.2k
  • 1
  • 14
  • 46

Doing kaplan meier plot with this data

I have normalized expression values of some genes in 76some patients and the how many days they have survived from their diagnosis with cancer like below

Doing kaplan meier plot with this data

I have normalized expression values of some genes in 76 patients and the how many days they have survived from their diagnosis with cancer like below

Doing plot with this data

I have normalized expression values of some genes in some patients and the how many days they have survived from their diagnosis with cancer like below

added 681 characters in body
Source Link
Zizogolu
  • 2.2k
  • 1
  • 14
  • 46

EDITED

I divided patients based on the median of survival days to Up and Down category like below but still I am failing to visualize that

> head(km)
     Sample Time        Gene Status
1 GSM482853   41  0.05649159    Low
2 GSM482857   41 -0.07667345    Low
3 GSM482866   54  0.10231150    Low
4 GSM482830   61 -0.05980938    Low
5 GSM482861   77  0.01231947    Low
6 GSM482818   78  0.21372177    Low
>

 fit <- survfit(Surv(Time, Status) ~ Gene, data = km)


> ggsurvplot(fit, data = km)
Error in data.frame(..., check.names = FALSE) : 
  arguments imply differing number of rows: 70, 0, 140

EDITED

I divided patients based on the median of survival days to Up and Down category like below but still I am failing to visualize that

> head(km)
     Sample Time        Gene Status
1 GSM482853   41  0.05649159    Low
2 GSM482857   41 -0.07667345    Low
3 GSM482866   54  0.10231150    Low
4 GSM482830   61 -0.05980938    Low
5 GSM482861   77  0.01231947    Low
6 GSM482818   78  0.21372177    Low
>

 fit <- survfit(Surv(Time, Status) ~ Gene, data = km)


> ggsurvplot(fit, data = km)
Error in data.frame(..., check.names = FALSE) : 
  arguments imply differing number of rows: 70, 0, 140
added 548 characters in body
Source Link
Zizogolu
  • 2.2k
  • 1
  • 14
  • 46
Loading
added 20 characters in body
Source Link
Zizogolu
  • 2.2k
  • 1
  • 14
  • 46
Loading
added 808 characters in body
Source Link
Zizogolu
  • 2.2k
  • 1
  • 14
  • 46
Loading
Source Link
Zizogolu
  • 2.2k
  • 1
  • 14
  • 46
Loading