Package nltk_lite :: Package parse :: Module tree :: Class ProbabilisticTree
[hide private]
[frames] | no frames]

Class ProbabilisticTree

source code

                object --+        
                         |        
                      list --+    
                             |    
                          Tree --+
                                 |
                    object --+   |
                             |   |
probability.ProbabilisticMixIn --+
                                 |
                                ProbabilisticTree

Instance Methods [hide private]
 
__init__(self, node, children, **prob_kwargs)
Construct a new tree.
source code
 
_frozen_class(self) source code
 
__repr__(self) source code
 
__str__(self) source code
 
__cmp__(self, other) source code
 
__eq__(self, other) source code
 
copy(self, deep=True) source code

Inherited from Tree: __add__, __delitem__, __ge__, __getitem__, __gt__, __le__, __lt__, __mul__, __ne__, __radd__, __rmul__, __setitem__, draw, flatten, freeze, height, leaves, pp, pp_latex_qtree, pp_treebank, productions, subtrees, treepositions

Inherited from Tree (private): _ppflat

Inherited from list: __contains__, __delslice__, __getattribute__, __getslice__, __hash__, __iadd__, __imul__, __iter__, __len__, __new__, __reversed__, __setslice__, append, count, extend, index, insert, pop, remove, reverse, sort

Inherited from probability.ProbabilisticMixIn: logprob, prob, set_logprob, set_prob

Inherited from object: __delattr__, __reduce__, __reduce_ex__, __setattr__

Class Methods [hide private]
 
convert(cls, val)
Convert a tree between different subtypes of Tree.
source code
Properties [hide private]

Inherited from object: __class__

Method Details [hide private]

__init__(self, node, children, **prob_kwargs)
(Constructor)

source code 

Construct a new tree.

Overrides: Tree.__init__
(inherited documentation)

_frozen_class(self)

source code 
Overrides: Tree._frozen_class

__repr__(self)
(Representation operator)

source code 
Overrides: Tree.__repr__

__str__(self)
(Informal representation operator)

source code 
Overrides: Tree.__str__

__cmp__(self, other)
(Comparison operator)

source code 
Overrides: Tree.__cmp__

__eq__(self, other)
(Equality operator)

source code 
Overrides: Tree.__eq__

copy(self, deep=True)

source code 
Overrides: Tree.copy

convert(cls, val)
Class Method

source code 

Convert a tree between different subtypes of Tree. cls determines which class will be used to encode the new tree.

Returns:
The new Tree.
Overrides: Tree.convert
(inherited documentation)