In the following error I think we could improve it in 2 ways:
- Make it so it says the error comes from
degree() not new_quant_param()
- Show that the wrong input was, in this case
integer not double
library(dials)
#> Loading required package: scales
degree(1L)
#> Error in `new_quant_param()`:
#> ! Since `type = 'double'`, please use that data type for the range.
#> Backtrace:
#> ▆
#> 1. └─dials::degree(1L)
#> 2. └─dials::new_quant_param(...)
#> 3. └─dials:::check_range(range, type, trans)
#> 4. └─rlang::abort(msg, call = call)
In the following error I think we could improve it in 2 ways:
degree()notnew_quant_param()integernotdouble