Open jonathandroth opened 7 years ago
@jonathandroth apologies for the slow response. Did you find a solution, and are you still interested in this?
@susanathey I worked around this by manually doing cross-validation, i.e. constructing folds myself, training the tree in K-1 of the folds, and then predicting and calculating the loss in the Kth fold.
I think it would be nice if this could be automated better, but I don't need an immediate fix for my current purposes.
Hi there,
The rpart function xpred.rpart is supposed to return predicted values from a tree under cross-validation. (I am trying to implement this along with causal tree since I'd like to choose my complexity parameter using a customized cross-validation criterion.)
However, when I use it with the output of a causalTree, it seems to predict the level of the y variable, rather than the treatment effect. An example is below:
Any help on this (or another way of implementing custom cross-validation criteria) would be appreciated! Thanks!