Re: [R] modification of cross-validations in rpart

2011-07-05 Thread Terry Therneau
> Is there a way to do this modification in rpart or is there any other > function I could use that would consider interdependence in the > response variable? This feature already exists: the "xval" option can be a vector of integers that defines the "left out" groups. First all the 1's are le

Re: [R] modification of cross-validations in rpart

2011-07-05 Thread Petr Savicky
On Mon, Jul 04, 2011 at 09:22:23AM -0400, Katerine Goyer wrote: > > Hello, > > I am using > the rpart function (from the rpart package) to do a regression tree that > would describe > the behaviour of a fish species according to several environmental variables. > For each fish (sampling unit),

Re: [R] modification of cross-validations in rpart

2011-07-04 Thread Weidong Gu
One way around hacking rpart is to write code to do K fold samples based on unit outside rpart, then build trees using training sets and summarize scores on testing sets. Weidong Gu On Mon, Jul 4, 2011 at 9:22 AM, Katerine Goyer wrote: > > > > > > > > Hello, > > > > I am using > the rpart functi

[R] modification of cross-validations in rpart

2011-07-04 Thread Katerine Goyer
Hello, I am using the rpart function (from the rpart package) to do a regression tree that would describe the behaviour of a fish species according to several environmental variables. For each fish (sampling unit), I have repeated observations of the response variable, which means that