Scaling

Learn how to scale data with scikit-learn.

Scaling means transforming numerical variables so that they have a similar scaleThe range or magnitude of values that the variable can take.. It’s an important step in the ML process because some algorithms are sensitive to the scale of the input variables. The scikit-learn library provides several methods for scaling numerical variables, including StandardScaler, MinMaxScaler, and RobustScaler.

To better illustrate this point, let’s take a look at how some algorithms can be impacted by the scale of the variables (this code is just for illustration purposes; there is no need to memorize it):

Get hands-on with 1400+ tech skills courses.