WeightedVariantContext

class corpustools.contextmanagers.WeightedVariantContext(corpus, sequence_type, type_or_token, attribute=None, frequency_threshold=0, log_count=True)[source]

Corpus context that weights frequency of pronunciation variants by the number of variants or the token frequency for transcriptions and tiers

See the documentation of BaseCorpusContext for additional information

Methods

__init__(corpus, sequence_type, type_or_token)

get_frequency_base([gramsize, halve_edges, ...])

Generate (and cache) frequencies for each segment in the Corpus.

get_phone_probs([gramsize, probability, ...])

Generate (and cache) phonotactic probabilities for segments in the Corpus.