NAME
Moot::Ngrams - libmoot : n-gram frequencies
SYNOPSIS
use Moot;
##=====================================================================
## Constructors etc
$ng = Moot::Ngrams->new;
$ng->clear();
##=====================================================================
## Accessors
$n_1g = $ng->n_1grams;
$n_2g = $ng->n_2grams;
$n_3g = $ng->n_3grams;
$n_tok = $ng->n_tokens;
$f1 = $ng->lookup($tag1);
$f12 = $ng->lookup($tag1,$tag2);
$f123 = $ng->lookup($tag1,$tag2,$tag3);
$ng->add_count($tag1, $f1);
$ng->add_count($tag1,$tag2, $f12);
$ng->add_count($tag1,$tag2,$tag3, $f123);
##=====================================================================
## I/O
$bool = $ng->loadFile($filename);
$bool = $ng->loadFh($fh, $name);
$ng = $CLASS_OR_OBJECT->load($filename_or_fh, $name)
$bool = $ng->saveFile($filename, $compact=0);
$bool = $ng->saveFh($fh, $name="$fh", $compact=0);
$bool = $ng->save($filename_or_fh, $name="$fh", $compact=0);
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.