NAME String::Random - Perl module to generate random strings based on a pattern VERSION version 0.32 SYNOPSIS use String::Random; my $string_gen = String::Random->new; print $string_gen->randregex('\d\d\d'); # Prints 3 random digits # Prints 3 random printable characters print $string_gen->randpattern("..."); or use String::Random qw(random_regex random_string); print random_regex('\d\d\d'); # Als
NAME Algorithm::SVM - Perl bindings for the libsvm Support Vector Machine library. SYNOPSIS use Algorithm::SVM; # Load the model stored in the file 'sample.model' $svm = new Algorithm::SVM(Model => 'sample.model'); # Classify a dataset. $ds1 = new Algorithm::SVM::DataSet(Label => 1, Data => [0.12, 0.25, 0.33, 0.98]); $res = $svm->predict($ds); # Train a new SVM on some new datasets. $svm->train(@t
NAME Benchmark - benchmark running times of Perl code SYNOPSIS use Benchmark qw(:all) ; timethis ($count, "code"); # Use Perl code in strings... timethese($count, { 'Name1' => '...code1...', 'Name2' => '...code2...', }); # ... or use subroutine references. timethese($count, { 'Name1' => sub { ...code1... }, 'Name2' => sub { ...code2... }, }); # cmpthese can be used both ways as well cmpthese($coun
NAME Geo::Hex - Convert between latitude/longitude and GeoHex code (version 2:world wide) SYNOPSIS use Geo::Hex; # From latitude/longitude to hex code my $code = latlng2geohex( $lat, $lng, $level ); # From hex code to center latitude/longitude my ( $center_lat, $center_lng, $level ) = geohex2latlng( $code ); # From latitude/longitude to zone object* my $zone = getZoneByLocation( $lat, $lng, $level
NAME local::lib - create and use a local lib/ for perl modules with PERL5LIB SYNOPSIS In code - use local::lib; # sets up a local lib at ~/perl5 use local::lib '~/foo'; # same, but ~/foo # Or... use FindBin; use local::lib "$FindBin::Bin/../support"; # app-local support library From the shell - # Install LWP and its missing dependencies to the '~/perl5' directory perl -MCPAN -Mlocal::lib -e 'CPAN:
NAME Proclet - minimalistic Supervisor SYNOPSIS use Proclet; my $proclet = Proclet->new( color => 1 ); # add service $proclet->service( code => sub { my $job = $jobqueue->grab; work($job); }, worker => 2, tag => 'worker' ); $proclet->service( code => sub { my $loader = Plack::Loader->load( 'Starlet', port => $port, host => $host || 0, max_workers => 4, ); $loader->run($app); }, tag => 'web' ); $pr
NAME Template - Front-end module to the Template Toolkit SYNOPSIS use Template; # some useful options (see below for full list) my $config = { INCLUDE_PATH => '/search/path', # or list ref INTERPOLATE => 1, # expand "$var" in plain text POST_CHOMP => 1, # cleanup whitespace PRE_PROCESS => 'header', # prefix each template EVAL_PERL => 1, # evaluate Perl code blocks }; # create Template object my $t
NAME Catalyst::Plugin::Scheduler - Schedule events to run in a cron-like fashion SYNOPSIS use Catalyst qw/Scheduler/; # run remove_sessions in the Cron controller every hour __PACKAGE__->schedule( at => '0 * * * *', event => '/cron/remove_sessions' ); # Run a subroutine at 4:05am every Sunday __PACKAGE__->schedule( at => '5 4 * * sun', event => \&do_stuff, ); # A long-running scheduled event that
NAME Algorithm::NaiveBayes - Bayesian prediction of categories SYNOPSIS use Algorithm::NaiveBayes; my $nb = Algorithm::NaiveBayes->new; $nb->add_instance (attributes => {foo => 1, bar => 1, baz => 3}, label => 'sports'); $nb->add_instance (attributes => {foo => 2, blurp => 1}, label => ['sports', 'finance']); ... repeat for several more instances, then: $nb->train; # Find results for unseen instan
NAME Data::Page - help when paging through sets of results SYNOPSIS use Data::Page; my $page = Data::Page->new(); $page->total_entries($total_entries); $page->entries_per_page($entries_per_page); $page->current_page($current_page); print " First page: ", $page->first_page, "\n"; print " Last page: ", $page->last_page, "\n"; print "First entry on page: ", $page->first, "\n"; print " Last entry on p
リリース、障害情報などのサービスのお知らせ
最新の人気エントリーの配信
処理を実行中です
j次のブックマーク
k前のブックマーク
lあとで読む
eコメント一覧を開く
oページを開く