From gmbecker at ucdavis.edu  Fri Aug 15 18:44:52 2014
From: gmbecker at ucdavis.edu (Gabriel Becker)
Date: Fri, 15 Aug 2014 09:44:52 -0700
Subject: [Rd] Request to review a patch for rpart
In-Reply-To: <53EB433D.5020101@ivt.baug.ethz.ch>
References: <53EB433D.5020101@ivt.baug.ethz.ch>
Message-ID: <CADwqtCMSarZp9Pv3RcOa7qazDjGCN1sNtvimu_QRVE3WpK9XpA@mail.gmail.com>

Kirill,

Perhaps I'm just being obtuse, but what are you proposing rpart do in the
case of an empty model?  Return a "tree" that always guesses the most
common label, or doesn't guess at all (NA)? It doesn't seem like you'd need
rpart for either of those.

~G


On Wed, Aug 13, 2014 at 3:51 AM, Kirill M?ller <
kirill.mueller at ivt.baug.ethz.ch> wrote:

> Dear list
>
>
> For my work, it would be helpful if rpart worked seamlessly with an empty
> model:
>
> library(rpart); rpart(formula=y~0, data=data.frame(y=factor(1:10)))
>
> Currently, an unrelated error (originating from na.rpart) is thrown.
>
> At some point in the near future, I'd like to release a package to CRAN
> which uses rpart and relies on that functionality. I have prepared a patch
> (minor modifications at three places, and a test) which I'd like to propose
> for inclusion in the next CRAN release of rpart. The patch can be reviewed
> at https://github.com/krlmlr/rpart/tree/empty-model, the files (based on
> the current CRAN release 4.1-8) can be downloaded from
> https://github.com/krlmlr/rpart/archive/empty-model.zip.
>
> Thanks for your attention.
>
>
> With kindest regards
>
> Kirill M?ller
>
> ______________________________________________
> R-devel at r-project.org mailing list
> https://stat.ethz.ch/mailman/listinfo/r-devel
>



-- 
Gabriel Becker
Graduate Student
Statistics Department
University of California, Davis

	[[alternative HTML version deleted]]



[Rd] Request to review a patch for rpart
Gabriel Becker