How can we deal with outliers?

Outliers can be handled in a variety of ways. Dropping them is one option. Outliers can only be removed if their values are inaccurate or severe. If a dataset containing baby weights contains a value of 98.6 degrees Fahrenheit, for example, it is erroneous. If the value is 187 kg, it is an extreme figure that is unsuitable for our model.
If the outliers aren’t quite so extreme, we can try:

  • This is a unique model. If we were using a linear model, for example, we may switch to a non-linear model.

  • The data will be normalized, bringing the extreme values closer to the other data points.

  • Using methods like random forest, which are less impacted by outliers.