# Introduction

In this series of evaluation metrics, so far we have discussed the Confusion matrix, Precision, and Recall, ROC etc. The metrics we discussed till now are generally used for classification problems. Now we will discuss the evaluation metric used for the regression problem.

Such evaluation metrics are Mean Absolute Error,  Root Mean Square Error etc.

First will discuss Mean Absolute Error.

## Mean Absolute Error

Let’s take an example of the most famous regression case study of “Predicting House Price”. There are no. of variables involved such as Area of a house, No. of bedrooms, Balcony area etc. On the basis of these attributes, will try to figure out the equation. On the basis, we are predicting the prices of the number of houses. Let’s say predicted value for ith house is Y^i

We are also available with the actual prices of houses. Let’s say actual value is represented for ith house by Yi By using these predicted and actual values will derive mean absolute error.

From the name, it suggests that there is a mean of some absolute value. The absolute value means even if no. is negative then it will treat as positive.

The equation for Mean Absolute Error is as follows-:

## MAE = ∑ abs(yiΛ – yi) / n

Here summation goes from 1 to n where n is the no. of observation. abs is the absolute function. MAE basically represents the difference between the continuous value.

## Root Mean Square Error

Root Mean Square Error is another metric for evaluation of the continuous values. It is the square root of the average of the squared differences of the actual and predicted value.

The formula for calculating the RSME for any model is as follows-:

## Comparing RSME and MAE

Now, we will see when to use which metric. It’s not judgemental that you have to use RSME or MAE. It depends on our data and model.