[R] Rpart question - labeling nodes with something not in x$frame

Peter Flom flom at ndri.org
Thu Jul 17 21:56:54 CEST 2003


I have a tree created with

tr.hh.logcas <- rpart(log(YCASSX + 1)~AGE+DRUGUSEY+SEX+OBSXNUM +WINDLE,
xval = 10)

I would like to label the nodes with YCASSX rather than log(YCASSX +
1).  But the help file for text in library rpart says that you can only
use labels that are part of x$frame, which YCASSX is not.

Is there a way to do what I want?

Thanks in advance

Peter

Peter L. Flom, PhD
Assistant Director, Statistics and Data Analysis Core
Center for Drug Use and HIV Research
National Development and Research Institutes
71 W. 23rd St
www.peterflom.com
New York, NY 10010
(212) 845-4485 (voice)
(917) 438-0894 (fax)




More information about the R-help mailing list