has_presystemic_metabolite#

pharmpy.modeling.has_presystemic_metabolite(model)[source]#

Checks whether a model has a presystemic metabolite

If pre-systemic drug there will be a flow from DEPOT to METABOLITE as well as being a flow from the CENTRAL to METABOLITE

Parameters:

model (Model) – Pharmpy model

Returns:

bool – Whether a model has presystemic metabolite

Examples

>>> from pharmpy.modeling import *
>>> model = load_example_model("pheno")
>>> model = add_metabolite(model, presystemic=True)
>>> has_presystemic_metabolite(model)
True