R/param_prop_terms.R

Defines functions prop_terms

Documented in prop_terms

#' Proportion of top predictors
#'
#' The parameter is used in models where a parameter is the proportion of
#' predictor variables.
#'
#' @inheritParams Laplace
#'
#' @details
#' `prop_terms()` is used in recipe stes in the \pkg{important} package.
#' @examples
#' prop_terms()
#' @export
prop_terms <- function(range = c(0.05, 1), trans = NULL) {
  new_quant_param(
    type = "double",
    range = range,
    inclusive = c(TRUE, TRUE),
    trans = trans,
    label = c(prop_terms = "Proportion of Top Predictors"),
    finalize = NULL
  )
}

Try the dials package in your browser

Any scripts or data that you put into this service are public.

dials documentation built on Nov. 11, 2026, 5:06 p.m.