File tree Expand file tree Collapse file tree 2 files changed +5
-7
lines changed
Expand file tree Collapse file tree 2 files changed +5
-7
lines changed Original file line number Diff line number Diff line change @@ -31,17 +31,15 @@ multi_predict <- function(object, ...) {
3131multi_predict.default <- function (object , ... ) {
3232 cli :: cli_abort(
3333 " No {.fun multi_predict} method exists for objects with classes
34- {.cls {class(object)}}." ,
35- call = rlang :: caller_env()
34+ {.cls {class(object)}}."
3635 )
3736}
3837
3938# ' @export
4039predict.model_spec <- function (object , ... ) {
4140 cli :: cli_abort(
4241 " You must {.fun fit} your {.help [model specification](parsnip::model_spec)}
43- before you can use {.fun predict}." ,
44- call = rlang :: caller_env()
42+ before you can use {.fun predict}."
4543 )
4644}
4745
Original file line number Diff line number Diff line change 33 Code
44 predict(lm_idea, mtcars)
55 Condition
6- Error:
6+ Error in `predict()` :
77 ! You must `fit()` your model specification (`?parsnip::model_spec()`) before you can use `predict()`.
88
99---
1010
1111 Code
1212 multi_predict(lm_fit, mtcars)
1313 Condition
14- Error:
14+ Error in `multi_predict()` :
1515 ! No `multi_predict()` method exists for objects with classes <_lm/model_fit>.
1616
1717---
1818
1919 Code
2020 multi_predict(extract_fit_engine(mars_fit), mtcars)
2121 Condition
22- Error:
22+ Error in `multi_predict()` :
2323 ! No `multi_predict()` method exists for objects with classes <earth>.
2424
2525# combine_words helper works
You can’t perform that action at this time.
0 commit comments