clophfit.fitting.odr ==================== .. py:module:: clophfit.fitting.odr .. autoapi-nested-parse:: Orthogonal Distance Regression (ODR) utilities and fitting pipeline. Functions --------- .. autoapisummary:: clophfit.fitting.odr.format_estimate clophfit.fitting.odr.generalized_combined_model clophfit.fitting.odr.fit_binding_odr clophfit.fitting.odr.outlier Module Contents --------------- .. py:function:: format_estimate(value, error, significant_digit_limit = 5) Format the value and its associated error into "{value} ± {error}" string. .. py:function:: generalized_combined_model(pars, x, dataset_lengths, *, is_ph) Handle multiple datasets with different lengths and masks. .. py:function:: fit_binding_odr(ds_or_fr, *, reweight = False, remove_outliers = None, max_iter = 15, tol = 0.1) Analyze multi-label titration datasets using ODR. :param ds_or_fr: Either a Dataset (will run initial LS fit) or a FitResult with initial params. :type ds_or_fr: Dataset | FitResult[MiniT] :param reweight: Whether to perform iterative reweighting (recursive ODR). :type reweight: bool :param remove_outliers: Outlier removal configuration, e.g., "zscore:2.5" or "zscore:2.5:5". If set, performs recursive ODR and masks outliers iteratively. :type remove_outliers: str | None :param max_iter: Maximum number of iterations for recursive ODR. :type max_iter: int :param tol: Convergence tolerance for residual variance. :type tol: float :returns: ODR fitting results. Residuals are WEIGHTED by the ORIGINAL y_err (before ODR modified it), making them comparable to LM residuals. :rtype: FitResult[odrpack.OdrResult] .. py:function:: outlier(output, *, threshold = 2.0, plot_z_scores = False) Identify outliers.