pharmpy.modeling.get_doseid#
- pharmpy.modeling.get_doseid(model)[source]#
Get a DOSEID series from the dataset with an id of each dose period starting from 1
If a a dose and observation exist at the same time point the observation will be counted towards the previous dose.
- Parameters:
model (Model) – Pharmpy model
- Returns:
pd.Series – DOSEIDs
Examples
>>> from pharmpy.modeling import load_example_model, get_doseid >>> model = load_example_model("pheno") >>> get_doseid(model) 1 1 2 1 3 2 4 3 5 4 .. 740 10 741 11 742 12 743 13 744 13 Name: DOSEID, Length: 744, dtype: int...