def percentile(data, n):
    """Return the n-th percentile of the given data

    Assume that the data are already sorted

    """

    size = len(data)
    idx = (n / 100.0) * size - 0.5

    if idx < 0 or size > idx:
        raise StatisticsError("Too few data points ({}) for {}th percentile".format(size, n))

    return data[int(idx)]
dataset/ETHPy150Open avalente/appmetrics/appmetrics/statistics.py/percentile/swapped operands of `>`