[R] tree.control

ripley@stats.ox.ac.uk ripley at stats.ox.ac.uk
Wed May 22 11:20:11 CEST 2002

On Wed, 22 May 2002 morganho at mail.telepac.pt wrote:

> Hi.
>      I'm trying to get a tree, that fits all the lines of the training set ( a tree with no error in classification)
>  data(iris)
>  tree.control(150,mindev=3D-1,minsize=3D2)

That gives me a syntax error, but I suspect the `3D' should be omitted.

>  ir.tr <- tree(Species ~., iris)
>  ir.tr
>  summary(ir.tr)
>      I'm trying to use this as a test, but it still have some examples  that are classified wrongly...
>      Anyone could tell me what's the problem?

You are not using tree.control correctly!  See ?tree.  Perhaps

ir.tr <- tree(Species ~., iris, minsize=0)

was what you meant.

Brian D. Ripley,                  ripley at stats.ox.ac.uk
Professor of Applied Statistics,  http://www.stats.ox.ac.uk/~ripley/
University of Oxford,             Tel:  +44 1865 272861 (self)
1 South Parks Road,                     +44 1865 272860 (secr)
Oxford OX1 3TG, UK                Fax:  +44 1865 272595

r-help mailing list -- Read http://www.ci.tuwien.ac.at/~hornik/R/R-FAQ.html
Send "info", "help", or "[un]subscribe"
(in the "body", not the subject !)  To: r-help-request at stat.math.ethz.ch

More information about the R-help mailing list