The London Perl and Raku Workshop takes place on 26th Oct 2024. If your company depends on Perl, please consider sponsoring and/or attending.

NAME

Moot::Lexfreqs - libmoot : lexical frequencies

SYNOPSIS

  use Moot;

  ##=====================================================================
  ## Constructors etc
  $lf = Moot::Lexfreqs->new;
  $lf->clear();

  ##=====================================================================
  ## Accessors
  $lf->add_count($word,$tag,$count);
  $lf->compute_specials();

  $npairs = $lf->n_pairs;
  $ntoks  = $lf->n_tokens;

  $f = $lf->f_word($word);
  $f = $lf->f_tag($tag);
  $f = $lf->f_word_tag($word,$tag);

  $f = $lf->lookup($word);          ##-- wrapper for f_word($word)
  $f = $lf->lookup(undef,$tag);     ##-- wrapper for f_tag($tag)
  $f = $lf->lookup($word,$tag);     ##-- wrapper for f_word_tag($word,$tag)

  ##=====================================================================
  ## I/O

  $bool = $lf->loadFile($filename);
  $bool = $lf->loadFh($fh,$name);
  $lf   = $CLASS_OR_OBJECT->load($filename_or_fh, $name)

  $bool = $lf->saveFile($filename);
  $bool = $lf->saveFh($fh,$name);
  $bool = $lf->save($filename_or_fh, $name);

DESCRIPTION

The Moot module provides an object-oriented interface to the libmoot library for Hidden Markov Model part-of-speech tagging.

SEE ALSO

Moot::constants(3perl), moot(1), perl(1).

AUTHOR

Bryan Jurish <moocow@cpan.org>

COPYRIGHT AND LICENSE

Copyright (C) 2011 by Bryan Jurish

This library is free software; you can redistribute it and/or modify it under the same terms as Perl itself, either Perl version 5.14.2 or, at your option, any later version of Perl 5 you may have available.