January 2020
Beginner to intermediate
372 pages
10h
English
In the Replacing categories with ordinal numbers recipe, we replaced categories with integers, which were assigned arbitrarily. This encoding works well with non-linear machine learning algorithms that can navigate through the arbitrarily assigned digits to try and find patterns that relate them to the target. However, this encoding method may not work so well with linear models.
We can instead assign integers to the categories given the target values. To do this, we do the following:
Read now
Unlock full access