Github user mpjlu commented on a diff in the pull request:

    https://github.com/apache/spark/pull/15647#discussion_r85310898
  
    --- Diff: docs/mllib-feature-extraction.md ---
    @@ -227,22 +227,19 @@ both speed and statistical learning behavior.
     
[`ChiSqSelector`](api/scala/index.html#org.apache.spark.mllib.feature.ChiSqSelector)
 implements
     Chi-Squared feature selection. It operates on labeled data with 
categorical features. ChiSqSelector uses the
     [Chi-Squared test of 
independence](https://en.wikipedia.org/wiki/Chi-squared_test) to decide which
    -features to choose. It supports three selection methods: `KBest`, 
`Percentile` and `FPR`:
    +features to choose. It supports three selection methods: `numTopFeatures`, 
`percentile`, `fpr`:
     
    -* `KBest` chooses the `k` top features according to a chi-squared test. 
This is akin to yielding the features with the most predictive power.
    -* `Percentile` is similar to `KBest` but chooses a fraction of all 
features instead of a fixed number.
    -* `FPR` chooses all features whose false positive rate meets some 
threshold.
    +* `numTopFeatures` chooses the `k` top features according to a chi-squared 
test. This is akin to yielding the features with the most predictive power.
    +* `percentile` is similar to `numTopFeatures` but chooses a fraction of 
all features instead of a fixed number.
    +* `fpr` chooses all features whose p-value is below a threshold, thus 
controlling the false positive rate of selection.
     
    -By default, the selection method is `KBest`, the default number of top 
features is 50. User can use
    -`setNumTopFeatures`, `setPercentile` and `setAlpha` to set different 
selection methods.
    +By default, the selection method is `numTopFeatures`, with the default 
number of top features set to 50. User can use
    +`setNumTopFeatures`, `setPercentile`, `fpr` to set different selection 
methods.
    --- End diff --
    
    ditto


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastruct...@apache.org or file a JIRA ticket
with INFRA.
---

---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscr...@spark.apache.org
For additional commands, e-mail: reviews-h...@spark.apache.org

Reply via email to