nltk.stem.util module

nltk.stem.util.prefix_replace(original, old, new)[source]

Replaces the old prefix of the original string by a new suffix

Parameters
  • original – string

  • old – string

  • new – string

Returns

string

nltk.stem.util.suffix_replace(original, old, new)[source]

Replaces the old suffix of the original string by a new suffix