data(titanic)
titanic <- titanic[complete.cases(titanic),]
model <- partykit::ctree(Survived ~ Sex + Pclass, data = titanic)
pred <- predict(model, type = "prob")[,"Yes"]
PerfsBinClassif(pred, titanic$Survived)
Run the code above in your browser using DataLab