Skip to content

Regression trees with an ordinal response variable

4 messages · Stacey Buckelew, Henric Nilsson (Public), Torsten Hothorn

#
Hi,

I am working on a regression tree in Rpart that uses a continuous response
variable that is ordered.  I read a previous response by Pfr. Ripley to a
inquiry regarding the ability of rpart to handle ordinal responses in
2003.  At that time rpart was unable to implement an algorithm to handle
ordinal responses.  Has there been any effort to rectify this in recent
years?

Thanks!

Stacey
On Mon, 2 Jun 2003, Andreas Christmann wrote:
They *can* be handled by tree or rpart in R.
I think Andy's point was that there is no consensus as to the right way to
handle them: certainly using the codes of categories works and may often
be reasonable, and treating ordinal responses as categorical is also very
often perfectly adequate.
Note that rpart is user-extensible, so it would be reasonably easy to write
an extension for a proportional-odds logistic regression model, if that is
thought appropriate (and it seems strange to me to impose such strong
structure on the model with such a general `linear predictor': POLR
models are often in my experience a poor reflection of real problems).
#
Den Fr, 2007-02-02, 06:03 skrev Stacey Buckelew:
The `ctree' function in the `party' package is able to handle ordered
responses, but note that there are fundamental differences between the
former and `rpart'. Reading the package vignette and the relevant
references will help.

However, at the moment there seems to be a problem related to the ordinal
case (predicted probabilities > 1) and I've CC:ed the package's maintainer
(Torsten Hothorn).


HTH,
Henric

- - - - -

Torsten, consider the following:
Warning message:
no admissible split found
[[1]]
[1] 1.822115

[[2]]
[1] 1.265487

[[3]]
[1] 1.822115

[[4]]
[1] 1.560440

[[5]]
[1] 1.822115
R version 2.4.1 Patched (2007-01-06 r40399)
i386-pc-mingw32

locale:
LC_COLLATE=Swedish_Sweden.1252;LC_CTYPE=Swedish_Sweden.1252;LC_MONETARY=Swedish_Sweden.1252;LC_NUMERIC=C;LC_TIME=Swedish_Sweden.1252

attached base packages:
 [1] "stats4"    "grid"      "splines"   "stats"     "graphics"  "grDevices"
 [7] "utils"     "datasets"  "methods"   "base"

other attached packages:
      party         vcd  colorspace        MASS strucchange    sandwich
    "0.9-8"     "1.0-2"      "0.95"    "7.2-31"     "1.3-1"     "2.0-1"
        zoo        coin     mvtnorm  modeltools    survival
    "1.2-2"     "0.5-2"     "0.7-5"    "0.2-10"      "2.30"
#
On Fri, 2 Feb 2007, Henric Nilsson (Public) wrote:

            
Hi Henric,
yep, you are right (as always)-- a bug introduced by a fix, grrr. Its a 
little bit more complicated, but I'll make correct predictions available 
again *asap*.

Thanks!

Torsten
1 day later
#
On Fri, 2 Feb 2007, Henric Nilsson (Public) wrote:

            
works again as advertised in party 0.9-9. Thanks for pointing this out!

Best wishes,

Torsten