Displaying 1 result from an estimated 1 matches for "cvtree".
Did you mean:
ctree
2004 Dec 17
0
(no subject)
...gt; Does anyone knows why or how to work on a class "tree" object so that
> "cv.tree" can handle it?
Please show how you did it the the error you got. I can't reproduce the
problem you described:
> library(tree)
> iris.tree <- tree(Species ~ ., iris)
> iris.cvtree <- cv.tree(iris.tree)
> iris.cvtree
$size
[1] 6 5 4 3 2 1
$dev
[1] 52.33779 45.94317 46.28027 63.43450 151.84608 335.57375
$k
[1] -Inf 4.228650 4.717398 15.957916 95.676543 190.954250
$method
[1] "deviance"
attr(,"class")
[1] "prune" &...