s-news
[Top] [All Lists]

[S] Rpart and NaN

To: s-news@wubios.wustl.edu
Subject: [S] Rpart and NaN
From: "Therneau, Terry M., Ph.D." <therneau@mayo.edu> (Terry Therneau)
Date: Sun, 31 Jan 1999 20:25:47 -0600
Cc: CHRIS.BARKER@roche.com, ripley@stats.ox.ac.uk
Sender: owner-s-news@wubios.wustl.edu

  If, as Brian R suggests, the problem really is an NaN you can either change
these values to NA or fix rpart to handle them.  
  To do the second, you need to change two lines in the call
to .C('s_to_rp', ...

  First, change the line  "as.integer(is.na(X))" to "as.integer(!is.finite(X))"
so that both NA's and NaN's are signalled to the underlying routine.
Second, add the specialsok=T argument as hypothesised by Brian.

  Perhaps I should just do this as a general change to the routine.  

        Terry T.


 Terry M. Therneau, Ph.D.                        (507) 284-3694 
 Head, Section of Biostatistics                  (507) 284-9542  FAX
 Mayo Clinic                                     therneau.terry@mayo.edu
 Rochester, Minn 55905
-----------------------------------------------------------------------
This message was distributed by s-news@wubios.wustl.edu.  To unsubscribe
send e-mail to s-news-request@wubios.wustl.edu with the BODY of the
message:  unsubscribe s-news

<Prev in Thread] Current Thread [Next in Thread>
  • [S] Rpart and NaN, Therneau, Terry M., Ph.D. <=