AI engineering glossary · Feature engineering data prep

What is mahalanobis distance?

Mahalanobis distance: A distance from a point to the centre of a distribution that accounts for the spread and correlation of the features, using the inverse covariance matrix: sqrt((x - mean)^T S^-1 (x - mean)). It is used to detect multivariate outliers.

Level: advancedTopic: Feature engineering data prep

Mahalanobis distance: an example

A person who is 150 cm tall and 90 kg may be unremarkable on each feature alone but far from the centre in Mahalanobis terms because the pair is unusual.

Related terms

More Feature engineering data prep terms

Where you learn it

Mahalanobis distance is part of the AI Engineering Program, which teaches it with notes, a hands-on lab and an exam. The first lesson is free.

Before you go

Take the cheat sheet with you

One free PDF: the key AI-engineering terms, formulas and Python idioms. No spam; unsubscribe any time.