-
-
Notifications
You must be signed in to change notification settings - Fork 25.8k
Median absolute error #3761
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Median absolute error #3761
Conversation
|
||
\text{MedAE}(y, \hat{y}) = \text{median}(\mid y_1 - \hat{y}_1 \mid, \ldots, \mid y_n - \hat{y}_n \mid). | ||
|
||
Here a small example of usage of the :func:`median_absolute_error` |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
"Here a" -> "Here is a"
Apart from that grammar typo, this LGTM; and thanks for the PEP8 fixes! |
Conflicts: doc/modules/model_evaluation.rst
add median absolute error (MAE) regression metric
Merged. Thanks! |
Thanks for your contribution and for making a separate pr! |
@FlorianWilhelm Is it the standard way to compute the median_absolute_error in the multi-output case
? |
I am not sure this is consistent with the averaging proposed in #3474. |
@arjoly I agree that it is not consistent. What we do here is to calculate the median over the flattened array. Functions like |
If we are unsure how to proceed now, I would raise an error for multi-output data. |
The median absolute error is a robust regression metric as suggested by @GaelVaroquaux in PR #2949 for the Theil-Sen regressor. @arjoly suggested to make this an own PR for clearer distinction.