R/is_default.R

Defines functions is_default

is_default <- function(arg,
                       val=get(arg, envir = parent.frame()),
                       func="use_workflow"){
  def <- eval(formals(get(func))[[arg]])
  # message("nm: ",arg)
  # message("val: ",val)
  # message("def: ",def)
  (is.null(def) & is.null(val)) || any(def==val)
}

Try the rworkflows package in your browser

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

rworkflows documentation built on May 29, 2024, 2:37 a.m.