Skip to contents

Does the model list refer to another model in the model list?

Usage

tar_nlmixr_multimodel_has_self_reference(model_list, name)

tar_nlmixr_multimodel_has_self_reference_single(model, name)

Arguments

model_list

A named list of calls for model targets to be created

name

Symbol, name of the target. A target name must be a valid name for a symbol in R, and it must not start with a dot. Subsequent targets can refer to this name symbolically to induce a dependency relationship: e.g. tar_target(downstream_target, f(upstream_target)) is a target named downstream_target which depends on a target upstream_target and a function f(). In addition, a target's name determines its random number generator seed. In this way, each target runs with a reproducible seed so someone else running the same pipeline should get the same results, and no two targets in the same pipeline share the same seed. (Even dynamic branches have different names and thus different seeds.) You can recover the seed of a completed target with tar_meta(your_target, seed) and run tar_seed_set() on the result to locally recreate the target's initial RNG state.

model

A single model call for the model target to be created

Value

A logical vector the same length as model_list indicating if the model is self-referential to another model in the list

Functions

  • tar_nlmixr_multimodel_has_self_reference_single(): A helper function to look at each call for each model separately