dpest.utils.pestmode#

dpest.utils.pestmode.pestmode(pst_path, new_value)[source]#

Updates the PESTMODE parameter in a PEST control (.pst) file.

The PESTMODE parameter specifies PEST’s mode of operation. Allowed values: “estimation”, “prediction”, “regularisation”, “pareto” (case-insensitive). The rest of the control file is preserved.

Required Arguments:#

  • pst_path (str):

    Path to the .pst file to modify

  • new_value (str):

    New value for PESTMODE (must be one of the allowed modes)

Returns:#

  • None

Example:#

Set PESTMODE to “prediction”

from dpest.utils import pestmode

pestmode("PEST_CONTROL.pst", "prediction")