set_iiv_on_ruv#
- pharmpy.modeling.set_iiv_on_ruv(model, dv=None, list_of_eps=None, same_eta=True, eta_names=None)[source]#
Multiplies epsilons with exponential (new) etas.
Initial variance for new etas is 0.09.
- Parameters:
model (Model) – Pharmpy model to apply IIV on epsilons.
list_of_eps (str, list) – Name/names of epsilons to multiply with exponential etas. If None, all epsilons will be chosen. None is default.
same_eta (bool) – Boolean of whether all RUVs from input should use the same new ETA or if one ETA should be created for each RUV. True is default.
eta_names (str, list) – Custom names of new etas. Must be equal to the number epsilons or 1 if same eta.
dv (Union[Expr, str, int, None]) – Name or DVID of dependent variable. None for the default (first or only)
- Returns:
Model – Pharmpy model object
Examples
>>> from pharmpy.modeling import * >>> model = load_example_model("pheno") >>> model = set_iiv_on_ruv(model) >>> model.statements.find_assignment("Y") ETA_RV1 Y = EPS₁⋅F⋅ℯ + F
See also