A RetroSearch Logo

Home - News ( United States | United Kingdom | Italy | Germany ) - Football scores

Search Query:

Showing content from https://github.com/signals-dev/Orion/issues/101 below:

Fixed threshold for `find_anomalies` · Issue #101 · sintel-dev/Orion · GitHub

Instead of using dynamic thresholding, a user might want to investigate fixed thresholds.

Definition of fixed threshold should be k standard deviations away from the mean using errors. The default k value is set to 4 since this obtained the best result through experimentation.

def _fixed_threshold(errors, k=4):
    """Calculate the threshold.

    The fixed threshold is defined as k standard deviations away from the mean.

    Args:
        errors (ndarray):
            Array of errors.

    Returns:
        float:
            Calculated threshold value.
    """
    mean = errors.mean()
    std = errors.std()

    return mean + k * std

RetroSearch is an open source project built by @garambo | Open a GitHub Issue

Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo

HTML: 3.2 | Encoding: UTF-8 | Version: 0.7.4