I just did an example in Actex where it created a tree using rpart. They then used cptable to find out which CP to use (after taking into account the one standard deviation rule) do get the correct tree to use. They then used prune and entered the desired CP to get a new tree.
Since we had to go through the trouble of figuring out the “best” CP and also how many terminal nodes there are couldn’t we just use rpart again but enter the correct CP and maxdepth arguments?
Is this just user preference or is there a reason to use prune and not rpart and the correct arguments?