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

    https://github.com/apache/spark/pull/15212#discussion_r84232802
  
    --- Diff: 
mllib/src/main/scala/org/apache/spark/mllib/feature/ChiSqSelector.scala ---
    @@ -243,6 +245,19 @@ class ChiSqSelector @Since("2.1.0") () extends 
Serializable {
           case ChiSqSelector.FPR =>
             chiSqTestResult
               .filter { case (res, _) => res.pValue < alpha }
    +      case ChiSqSelector.FDR =>
    +        val tempRDD = chiSqTestResult
    +          .sortBy { case (res, _) => res.pValue }
    +        val maxIndex = tempRDD
    +          .zipWithIndex
    --- End diff --
    
    I have added a large size data sample in the test Suite, and updated the 
Contingency tables in the test Suite comments. The value of degree of freedom, 
statistic and pValue for each feature is also added. so it is easy to validate 
the result.
    
    SelectFDR in sklearn is not exact. My PR to fix the bug is merged today. 


---
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