[R] Regression tree: labels in the terminal nodes
Juergen.Kuehn at zalf.de
Thu Aug 16 13:50:44 CEST 2007
I'm a new user of R 2.4.1 and I'm searching for information on improving
the output of regression tree graphs.
In the terminal nodes I am up to now able to indicate the number of
values (n) and the mean of all values in this terminal node by the command
> text(tree, use.n=T, xpd=T)
Yet I would like to indicate automatically in the output graph of the
tree some quality measure, e.g. impurity (or standard deviation .....)
and a character to identify which cases are in one terminal node, e.g.
given a ID number or name.
Until now I did not discover in my R help scripts or in the R programm
help how to do it. So I calculate impurity by hand, and I'm identifying
the cases in each node "by hand", and I am adding these values with a
graphical software to the graph (as e.g. given "*.jpg" file). Therefore
anybody can see that I added these values by hand. I'm quite sure that
there is a more easy and faster way which looks (and is!) more professional.
Could anybody help me? That would be great!
Thank you very much for your support!
Dr. Jürgen Kühn
Leibniz-Centre for Agricultural Landscape Research (ZALF)
Institute of Soil Landscape Research_
Eberswalder Str. 84
E-mail: Juergen.Kuehn at zalf.de <mailto:Juergen.Kuehn at zalf.de>
More information about the R-help