def fepsilon(L: list):
    if ((self.parameters['p'] > 0) or (self.parameters['P'] > 0)):
        L_tmp = sub_arp(L)
    else:
        L_tmp = L
    try:
        result = (L_tmp[(- 1)] - self.ma_avg_)
        for i in range(1, self.parameters['max_pik']):
            result -= (self.ma_piq_.values['coefficient'][i] * (L_tmp[(- i)] - self.ma_avg_))
        return result
    except:
        return 0
def fepsilon(L: list):
    if ((self.parameters['p'] > 0) or (self.parameters['P'] > 0)):
        L_tmp = sub_arp(L)
    else:
        L_tmp = L
    try:
        result = (L_tmp[(- 1)] - self.ma_avg_)
        for i in range(1, self.parameters['max_pik']):
            result -= (self.ma_piq_.values['coefficient'][i] * (L_tmp[(- i)] - self.ma_avg_))
        return result
    except:
        return 0