huaxingao opened a new pull request #31160:
URL: https://github.com/apache/spark/pull/31160


   ### What changes were proposed in this pull request?
   Add UnivariateFeatureSelector
   
   ### Why are the changes needed?
   Have one UnivariateFeatureSelector, so we don't need to have three Feature 
Selectors.
   
   
   ### Does this PR introduce _any_ user-facing change?
   Yes
   ```
   selector = UnivariateFeatureSelector(featureCols=["x", "y", "z"], 
labelCol=["target"], featureType="categorical", labelType="continuous", 
selectorType="numTopFeatures",  numTopFeatures=100)
   ```
   
   Or
   
   numTopFeatures
   ```
   selector = UnivariateFeatureSelector(featureCols=["x", "y", "z"], 
labelCol=["target"], scoreFunction="f_classif", selectorType="numTopFeatures",  
numTopFeatures=100)
   ```
   
   ### How was this patch tested?
   Add Unit test
   


----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
[email protected]



---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to