hytest-org / hytest

https://hytest-org.github.io/hytest/
22 stars 10 forks source link

Miscellaneous metrics notebook #330

Closed alaws-USGS closed 1 year ago

alaws-USGS commented 1 year ago

Create Metrics_Miscellaneous_v1.ipynb and put the following equations in it:

# Custom stat functions
def bias(obs, est):
    return obs - est

def mae(obs, est, n):
    return sum(abs(obs - est))/n

def rmse(obs, est):
    return math.sqrt(np.square(np.subtract(obs, est)).mean())