topepo / caret

caret (Classification And Regression Training) R package that contains misc functions for training and plotting classification and regression models
http://topepo.github.io/caret/index.html
1.61k stars 634 forks source link

Meaningful error message when using prSummary with classProbs=FALSE #1274

Closed xabriel closed 2 years ago

xabriel commented 2 years ago

When classProbs=FALSE, prSummary() fails without letting the user know what to do.

This PR makes the prSummary() function fail similarly as twoClassSummary() when a user forgot to set classProbs=TRUE.

xabriel commented 2 years ago

@topepo just wanted to ping you in case you missed this PR. Let me know if it is helpful. Thanks.

topepo commented 2 years ago

Thanks for the contribution and waiting so long. I'll update from main and merge 👍