calc_extrema¶
-
calc_extrema
(x: numpy.ndarray, func: Callable, param_df: pandas.core.frame.DataFrame, func_options: dict = {}, brute_force_extrema: bool = False) → Tuple[numpy.ndarray][source]¶ Calculates the supremum and infimum of a given function func, with the parameters and their errors given by param_df, over the values of x.
- Parameters
x (np.ndarray) – Values the supremum and infimum should be calculated over
func (Callable) – Functions used to calculate the supremum and infimum
param_df (pd.DataFrame) – DataFrame with parameters and errors
func_options (dict, optional) – options for func, by default {}
brute_force_extrema (bool, optional) – Whether or not to calculate supremum and infimum from all permutations of adding and subtracting the errors from the parameters. For some functions, i.e. the logistic curve, this is needed, since simply adding or subtracting the errors from the parameter can lead to supremum and/or infimum to cross the result with the exact parameters., by default False
- Returns
supremum, infimum
- Return type
Tuple[np.ndarray]