Re: [R] Getting HR from Cox model in R

2014-12-29 Thread Michael Dewey
Comments in line On 24/12/2014 22:09, Ruzan Udumyan wrote: Dear Michael, Thank you very much for your reply. The more complete information is as follows: I want to do a mediation analysis following the below-mentioned syntax from: http://www.biomedcentral.com/content/supplementary/1471-2288-14

Re: [R] Getting HR from Cox model in R

2014-12-24 Thread Ruzan Udumyan
Dear Michael, Thank you very much for your reply. The more complete information is as follows: I want to do a mediation analysis following the below-mentioned syntax from: http://www.biomedcentral.com/content/supplementary/1471-2288-14-9-s1.pdf I did not define categorical variables as logical v

Re: [R] Getting HR from Cox model in R

2014-12-23 Thread Michael Dewey
Inline comments On 23/12/2014 09:42, Ruzan Udumyan wrote: Dear All, I am not familiar with R language well. Could you please help me interpret these commands?: TE = exp(sum(coef(cox)[c('aTRUE', 'bTRUE')])) - does it mean exp(coef(a variable) + coef(b variable)) ? You have not given us m

[R] Getting HR from Cox model in R

2014-12-23 Thread Ruzan Udumyan
Dear All, I am not familiar with R language well. Could you please help me interpret these commands?: TE = exp(sum(coef(cox)[c('aTRUE', 'bTRUE')])) - does it mean exp(coef(a variable) + coef(b variable)) ? DE = exp(unname(coef(cox)['aTRUE'])) - what is unname for ? Thank you very much befo