-
-
Notifications
You must be signed in to change notification settings - Fork 26.2k
Open
Labels
ModerateAnything that requires some knowledge of conventions and best practicesAnything that requires some knowledge of conventions and best practicesNew Feature
Description
Describe the workflow you want to enable
Would be good to get sample_weight support for QuantileTransformer for dealing with sparse or imbalanced data, a la #15601.
scaler = QuantileTransformer(output_distribution="normal")
scaler.fit(X, sample_weight=w)
Describe your proposed solution
As far as I know it would just require adding the weight argument to the quantiles_ computation in np.nanpercentile.
KBinsDiscretizer
supports sample_weight and with strategy='quantile', encode='ordinal' this behavior can be achieved but it is much, much slower.
Describe alternatives you've considered, if relevant
No response
Additional context
No response
ogrisel
Metadata
Metadata
Assignees
Labels
ModerateAnything that requires some knowledge of conventions and best practicesAnything that requires some knowledge of conventions and best practicesNew Feature
Type
Projects
Status
Todo