nltk.ProbabilisticProduction.__init__

ProbabilisticProduction.__init__(lhs, rhs, **prob)[source]

Construct a new ProbabilisticProduction.

Parameters:
  • lhs (Nonterminal) – The left-hand side of the new ProbabilisticProduction.
  • rhs (sequence(Nonterminal and terminal)) – The right-hand side of the new ProbabilisticProduction.
  • prob – Probability parameters of the new ProbabilisticProduction.