What is the difference between Transformer and Estimator in Scikit-Learn?

Updated May 17, 2026

Short answer

Estimators learn from data using fit(), while transformers additionally modify data using transform().

Deep explanation

In Scikit-Learn’s API design, an estimator is any object that learns from data via fit(). A transformer is a specialized estimator that implements transform() (and often fit_transform()). Transformers are used in preprocessing pipelines, while estimators include predictive models like classifiers and regressors. This distinction is central to Scikit-Learn’s composability philosophy.

Unlock with a Pro subscription to view this section.

View pricing

Real-world example

No real-world example available yet.

Unlock with a Pro subscription to view this section.

Upgrade to Pro

Common mistakes

No common mistakes listed yet.

Unlock with a Pro subscription to view this section.

Upgrade to Pro

Follow-up questions

No follow-up questions available yet.

Unlock with a Pro subscription to view this section.

Upgrade to Pro

More Scikit-Learn interview questions

View all →