Incorrect search filter: invalid characters - *.p[ml]
AI-NaiveBayes

 view release on metacpan or  search on metacpan

INSTALL  view on Meta::CPAN

Alternatively, if your CPAN shell is set up, you should just be able to do:

    % cpan AI::NaiveBayes

## Manual installation

As a last resort, you can manually install it. Download the tarball, untar it,
then build it:

    % perl Makefile.PL
    % make && make test

Then install it:

    % make install

If your perl is system-managed, you can create a local::lib in your home
directory to install modules to. For details, see the local::lib documentation:
https://metacpan.org/pod/local::lib

## Documentation

LICENSE  view on Meta::CPAN

OUT OF THE USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED
TO LOSS OF DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY
YOU OR THIRD PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER
PROGRAMS), EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE
POSSIBILITY OF SUCH DAMAGES.

                     END OF TERMS AND CONDITIONS

        Appendix: How to Apply These Terms to Your New Programs

  If you develop a new program, and you want it to be of the greatest
possible use to humanity, the best way to achieve this is to make it
free software which everyone can redistribute and change under these
terms.

  To do so, attach the following notices to the program.  It is safest to
attach them to the start of each source file to most effectively convey
the exclusion of warranty; and each file should have at least the
"copyright" line and a pointer to where the full notice is found.

    <one line to give the program's name and a brief idea of what it does.>

META.json  view on Meta::CPAN

         "requires" : {
            "File::Find::Rule" : "0.32",
            "List::Util" : "0",
            "Moose" : "1.15",
            "MooseX::Storage" : "0.25",
            "perl" : "5.010",
            "strict" : "0",
            "warnings" : "0"
         }
      },
      "test" : {
         "requires" : {
            "Test::More" : "0"
         }
      }
   },
   "release_status" : "stable",
   "resources" : {
      "repository" : {
         "type" : "git",
         "web" : "http://github.com/zby/AI-NaiveBayes"

Makefile.PL  view on Meta::CPAN

    "List::Util" => 0,
    "Moose" => "1.15",
    "MooseX::Storage" => "0.25",
    "strict" => 0,
    "warnings" => 0
  },
  "TEST_REQUIRES" => {
    "Test::More" => 0
  },
  "VERSION" => "0.04",
  "test" => {
    "TESTS" => "t/*.t"
  }
);


my %FallbackPrereqs = (
  "File::Find::Rule" => "0.32",
  "List::Util" => 0,
  "Moose" => "1.15",
  "MooseX::Storage" => "0.25",

t/01-learner.t  view on Meta::CPAN

use strict;
use warnings;
use Test::More tests => 11;
use AI::NaiveBayes::Learner;
ok(1); # If we made it this far, we're loaded.

my $learner = AI::NaiveBayes::Learner->new();

# Populate
$learner->add_example( attributes => _hash(qw(sheep very valuable farming)),
		   labels => ['farming'] );
is $learner->{labels}{farming}{count}, 1;

t/02-predict.t  view on Meta::CPAN

use strict;
use warnings;
use Test::More tests => 12;
use AI::NaiveBayes;
use AI::NaiveBayes::Learner;
ok(1); # If we made it this far, we're loaded.

my $lr = AI::NaiveBayes::Learner->new();

# Populate
$lr->add_example( attributes => _hash(qw(sheep very valuable farming)),
           labels => ['farming'] );
$lr->add_example( attributes => _hash(qw(farming requires many kinds animals)),

t/author-pod-coverage.t  view on Meta::CPAN

#!perl

BEGIN {
  unless ($ENV{AUTHOR_TESTING}) {
    print qq{1..0 # SKIP these tests are for testing by the author\n};
    exit
  }
}

# This file was automatically generated by Dist::Zilla::Plugin::PodCoverageTests.

use Test::Pod::Coverage 1.08;
use Pod::Coverage::TrustPod;

all_pod_coverage_ok({ coverage_class => 'Pod::Coverage::TrustPod' });

t/author-pod-syntax.t  view on Meta::CPAN

#!perl

BEGIN {
  unless ($ENV{AUTHOR_TESTING}) {
    print qq{1..0 # SKIP these tests are for testing by the author\n};
    exit
  }
}

# This file was automatically generated by Dist::Zilla::Plugin::PodSyntaxTests.
use strict; use warnings;
use Test::More;
use Test::Pod 1.41;

all_pod_files_ok();

t/default_training.t  view on Meta::CPAN

use strict;
use Test::More tests => 2;
use AI::NaiveBayes;
ok(1); # If we made it this far, we're loaded.

my $classifier = AI::NaiveBayes->train( 
    {
        attributes => _hash(qw(sheep very valuable farming)),
        labels => ['farming']
    },
    {
        attributes => _hash(qw(vampires cannot see their images mirrors)),



( run in 0.286 second using v1.01-cache-2.11-cpan-3cd7ad12f66 )