Dear all: I have used the cph function in the rms package. log10 was used to transform the variables, as follows: fit<-cph(pfsurv~log10(x1)+log10(x2),x=T,y=T,surv=T) after I run the nomogram function. I found "variable limits and transformations are such that an infinite axis value has resulted." How to add variable limits in the nomogram function? Thanks a lot *Yao Zhu* *Department of Urology Fudan University Shanghai Cancer Center Shanghai, China* [[alternative HTML version deleted]]
Frank Harrell
2011-Feb-26 14:43 UTC
[R] tansformation of variables in cph from rms package
Yao, I wonder how likely it is that log transformations fit the data. More often I find that the flexibility of restricted cubic splines is needed. One of the things that people take for granted when using log() is that they are assuming that k=0 in making the transformation log(x + k). It is often the case the the proper origin is not zero. This also impacts the problem you encountered. Besides all that, you can specify limits to predictors to nomogram() in a variety of ways as listed in the help file. Try that. Frank ----- Frank Harrell Department of Biostatistics, Vanderbilt University -- View this message in context: http://r.789695.n4.nabble.com/tansformation-of-variables-in-cph-from-rms-package-tp3325545p3325911.html Sent from the R help mailing list archive at Nabble.com.
On 26.02.2011 15:43, Frank Harrell wrote:> Yao, > > I wonder how likely it is that log transformations fit the data. More often > I find that the flexibility of restricted cubic splines is needed. > > One of the things that people take for granted when using log() is that they > are assuming that k=0 in making the transformation log(x + k). It is often > the case the the proper origin is not zero. This also impacts the problem > you encountered. > > Besides all that, you can specify limits to predictors to nomogram() in a > variety of ways as listed in the help file. Try that. > Frank > > ----- > Frank Harrell > Department of Biostatistics, Vanderbilt UniversityFrank, looks like you are also using this Nabble interface now: 1. You have written to the R-help mailing list only rather than to "Yao". Please answer also directly: not all posters are on the mailing list. 2. Please quote the original question, otherwise readers of the list cannot remember and do not learn too much without having the context apparent. Best, Uwe
Apparently Analagous Threads
- cph/nomogram Design/RMS package hazard ratio: interquartile vs per unit
- Nomogram with stratified cph in rms package, how to get failure probability
- How to make a nomogam and Calibration plot
- Nomogram with stratified cph in Design package-- failure probability
- Nomogram with multiple interactions (package rms)