update_in_env: Update a model in the environment the model was created in

View source: R/utils.R

update_in_envR Documentation

Update a model in the environment the model was created in

Description

stats::update() will perform the update in parent.frame() by default, but this can cause problems when the update is called by another function (so the parent frame is no longer the environment the user is in).

Usage

update_in_env(object, formula., ...)

Arguments

object

An existing fit from a model function such as lm(), glm() and many others.

formula.

Changes to the formula – see update.formula for details.

...

Additional arguments to the call, or arguments with changed values. Use name = NULL to remove the argument name.

Value

The updated model is returned.


UCLATALL/supernova documentation built on Feb. 13, 2024, 6:57 a.m.