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

    https://github.com/apache/spark/pull/3305#discussion_r20455531
  
    --- Diff: python/pyspark/mllib/classification.py ---
    @@ -29,47 +30,96 @@
                'SVMWithSGD', 'NaiveBayesModel', 'NaiveBayes']
     
     
    -class LogisticRegressionModel(LinearModel):
    +class ClassificationModel(LinearModel):
    +    """
    +    :: Experimental ::
    +
    +    Represents a classification model that predicts to which of a set of 
categories an example
    +    belongs. The categories are represented by double values: 0.0, 1.0, 
2.0, etc.
    +    """
    +    def __init__(self, weights, intercept):
    +        super(ClassificationModel, self).__init__(weights, intercept)
    +        self._threshold = 0.5
    --- End diff --
    
    Can we set default to `None` here, and set 0.5 and 0.0 in LR and SVM, 
respectively? It's a little strange to put 0.5 here.


---
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 [email protected] or file a JIRA ticket
with INFRA.
---

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

Reply via email to