sklearn.metrics.median_absolute_error(y_true, y_pred)
[source]
Median absolute error regression loss
Read more in the User Guide.
Parameters: |
|
---|---|
Returns: |
|
>>> from sklearn.metrics import median_absolute_error >>> y_true = [3, -0.5, 2, 7] >>> y_pred = [2.5, 0.0, 2, 8] >>> median_absolute_error(y_true, y_pred) 0.5
sklearn.metrics.median_absolute_error
© 2007–2018 The scikit-learn developers
Licensed under the 3-clause BSD License.
http://scikit-learn.org/stable/modules/generated/sklearn.metrics.median_absolute_error.html