The way data is preprocessed can have a huge effect in your scikit-learn pipelines. This series of videos will highlight common techniques for preprocessing data for modelling.

Untitled

Scale with StandardScaler: Make the x and y axis more in line to each other (link).

Anschließend sehen wir Nachteile von StandardScaler (Outliers).

Untitled

There actually some other techniques that are robust against outliers

Scale with Quantile: sehr schöne Visualisierung. Es wird klar, warum die Werte näher zusammerücken.

Untitled

Standard vs. Quantile: Im Beispiel gewinnt Quantile. Visuelle Begründung hier.

Nonlinear dataset:

Untitled

OneHotEncoder: Kategorische Daten. Wie gehe ich mit unknown Kategorien um? Dafür gibt es den handle_unknown Parameter. Dieser verhindert Fehlermeldungen. Sollte nicht auf Target-Variable angewendet werden! Siehe auch hier.