In R, rpart function allows me to set different class priors through 'parms'. How do I set this while using the train function in caret?
Asked
Active
Viewed 260 times
1 Answers
0
You include it inside train
function.
As example:
library("caret")
train(Kyphosis ~ Age + Number + Start, data = kyphosis, method = "rpart",
parms = list(prior = c(0.65, 0.35)))

Lluís Ramon
- 576
- 4
- 7