read_model_from_string#
- pharmpy.modeling.read_model_from_string(code)[source]#
Read model from the model code in a string
- Parameters:
code (str) – Model code to read
- Returns:
Model – Pharmpy model object
Example
>>> from pharmpy.modeling import read_model_from_string >>> s = '''$PROBLEM ... $INPUT ID DV TIME ... $DATA file.csv ... $PRED ... Y=THETA(1)+ETA(1)+ERR(1) ... $THETA 1 ... $OMEGA 0.1 ... $SIGMA 1 ... $ESTIMATION METHOD=1''' >>> read_model_from_string(s) <...>
See also
read_model
Read model from file
read_model_from_database
Read model from database