Skip to main content

Module stat_selectors

Module stat_selectors 

Source
Expand description

Statistical-test-based feature selectors.

Three selectors that choose features based on p-values obtained from a statistical test (e.g., ANOVA F-test, chi-squared test):

  • SelectFpr โ€” False Positive Rate: selects every feature whose p-value is below alpha.
  • SelectFdr โ€” False Discovery Rate: applies the Benjamini-Hochberg procedure to control the expected proportion of false positives.
  • SelectFwe โ€” Family-Wise Error: applies the Bonferroni correction (alpha / n_features) to control the probability of any false positive.

All three take a pre-computed vector of p-values (one per feature) at fit time, allowing integration with any upstream scoring function.

Structsยง

FittedSelectFdr
A fitted SelectFdr holding the selected indices.
FittedSelectFpr
A fitted SelectFpr holding the selected indices.
FittedSelectFwe
A fitted SelectFwe holding the selected indices.
SelectFdr
Select features controlling the false discovery rate via the Benjamini-Hochberg procedure.
SelectFpr
Select features with p-values below alpha.
SelectFwe
Select features controlling the family-wise error rate via the Bonferroni correction.