thouska / spotpy

A Statistical Parameter Optimization Tool
https://spotpy.readthedocs.io/en/latest/
MIT License
247 stars 149 forks source link

Possible error in analyser.py #276

Open yulijun1220 opened 2 years ago

yulijun1220 commented 2 years ago

Hallo, Houska.

Thank you for such an excellent tool. I'm using the GLUE. I think there might be some mini-mistake on the file analyser.py(line276-279)
if maximize: index = np.where(results['like1']>=np.percentile(results['like1'],100.0-percentage)) else: index = np.where(results['like1']>=np.percentile(results['like1'],100.0-percentage)). you see, whether maximize is true or false, the results will be the same.

So, I change it as follows: if maximize: index = np.where(results['like1']>=np.percentile(results['like1'],100.0-percentage)) else: index = np.where(results['like1']<=np.percentile(results['like1'],percentage)).