Skip to contents

Recover the function that created a model

Usage

whomademe(x, ...)

Arguments

x

A character giving the name of a model. To be passed to model_name().

...

currently ignored

Value

A function

Details

Model objects (inheriting from mod_cpt) know the name of the function that created them. whomademe() returns that function.

See also

Examples

# Get the function that made a model
f <- whomademe(fit_meanshift_norm(CET, tau = 42))
str(f)
#> function (x, tau, ...)  
#>  - attr(*, "model_name")= chr "meanshift_norm"
#>  - attr(*, "class")= chr "fun_cpt"