The Perl Toolchain Summit needs more sponsors. If your company depends on Perl, please support this very important event.

NAME

Candidates - Perl5 module for manipulating candidate features (help module for Statistics::MaxEntropy)

SYNOPSIS

  use Statistics::Candidates;

  # create a new candidates object and read candidate features
  $candidates = Statistics::Candidates->new($some_file);

  # checks for constant candidate features
  $candidates->check();

  # writes candidates that were not added to a file
  $candidates->write($some_other_file);

  # clear the administration about being added or not ...
  $candidates->clear();

DESCRIPTION

The Candidates object is for storage, retrieval, and manipulation of candidate features. This module requires Bit::SparseVector.

METHODS

new
 $candidates = Statistics::Candidates->new($file);
check
 $candidates->check();
write
 $candidates->write($file);
clear
 $candidates->clear();

FILE SYNTAX

The syntax of the candidate feature file is more or less the same as that for the events file:

  • each line is an event (events specified in the same order as the events file);

  • each column is a feature;

  • constant feature functions are forbidden;

  • values are 0 or 1;

  • no space between features;

  • lines that start with # are ignored.

Below is a set of candidates for m events, c candidate features; f_ij are bits:

    name_1 <tab> name_2 ... name_c-1 <tab> name_c <cr>
    f_11 f_12 ... f_1c-1 f_1c <cr>
               .
               .
               .
    f_i1 f_i2 ... f_ic-1 f_ic <cr>
               .
               .
               .
    f_m1 f_m2 ... f_mc-1 f_mc <cr>

SEE ALSO

Statistics::MaxEntropy, Statistics::SparseVector.

VERSION

Version 0.1

AUTHOR

COPYRIGHT

Statistics::Candidates comes with ABSOLUTELY NO WARRANTY and may be copied only under the terms of the GNU Library General Public License (version 2, or later), which may be found in the distribution.