[R] Calculating Rsquared values in rpart
anditopark at hotmail.com
Thu Dec 13 22:40:21 CET 2007
In rpart, one can get a graph of R-squared (using rsq.rpart (fit)), in which the x axis is the number of splits, and which contains two lines - an "apparent" R squared and an Rsquared based on the x error.
I would like to caclulate these R-squared values, but cannot work out from the output how it is done. Is there any way to access the values that underpin this graph? Alternatively, is there any way to calculate them from the summary data?
Thanks in advance,
[[replacing trailing spam]]
More information about the R-help