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

    https://github.com/apache/spark/pull/7095#discussion_r33527629
  
    --- Diff: python/pyspark/ml/regression.py ---
    @@ -239,7 +243,36 @@ def getImpurity(self):
             return self.getOrDefault(self.impurity)
     
     
    -class DecisionTreeRegressionModel(JavaModel):
    +@inherit_doc
    +class DecisionTreeModel(JavaModel):
    +
    +    @property
    +    def numNodes(self):
    +        """Return number of nodes of the decision tree."""
    +        return self._call_java("numNodes")
    +
    +    @property
    +    def depth(self):
    +        """Return depth of the decision tree."""
    +        return self._call_java("depth")
    +
    +    def __repr__(self):
    +        return self._call_java("toString")
    +
    +
    +@inherit_doc
    +class treeEnsembleModels(JavaModel):
    --- End diff --
    
    "*T*reeEnsembleModel"


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