NAME

Statistics::Discrete - Perl extension for blah blah blah

SYNOPSIS

 use Statistics::Discrete;

 # construct a new class
 my $sd = Statistics::Discrete->new();
 
 # add data using an array
 $sd->add_data((2,5,7,2,1,7,3,3,7,333));
 
 # ---- Descriptive Statistics ---- #

 # Count the number of samples
 my $count = $sd->count(); 
 # Minimum data value
 my $min = $sd->minimum(); 
 # Maximum data value
 my $max = $sd->maximum(); 
 # Mean 
 my $mean = $sd->mean(); 
 # Variance
 my $variance = $sd->variance(); 
 # Standard Deviation
 my $standard_deviation = $sd->standard_deviation(); 


 # ---- Distributions ---- #

 my $fd = $sd->frequency_distribution();
 my $pmf = $sd->probability_mass_function();
 my $cdf = $sd->empirical_distribution_function();
 my $ccdf = $sd->complementary_cumulative_distribution_function();


 # ---- Binning ---- #
 # binning influences the way the distributions
 # are returned
 my $binning_type = NO_BINNING;   # DEFAULT
 $binning_type = LIN_BINNING; 
 $binning_type = LOG_BINNING; 
 $sd->set_binning_type($binning_type);

 $sd->set_optimal_binning();
 my $num_of_bins = 3;
 $sd->set_custom_num_bins($num_of_bins);
 
 # return the bins currently used
 my $cur_bins = $sd->bins();

 # compute linear bins starting from the data
 my $lin_bins = $sd->compute_lin_bins($num_of_bins);
 my $log_bins = $sd->compute_log_bins($num_of_bins);

 # ---- Data Input ---- #

 # add data from file
 $sd->add_data_from_file("./data.txt"); 

DESCRIPTION

Stub documentation for Statistics::Discrete, created by h2xs.

TODO: work in progress

EXPORT

None by default.

SEE ALSO

Mention other useful documentation such as the documentation of related modules or operating system documentation (such as man pages in UNIX), or any relevant external documentation such as RFCs or standards.

If you have a mailing list set up for your module, mention it here.

If you have a web site set up for your module, mention it here.

AUTHOR

Chiara Orsini, <chiara@caida.org>

COPYRIGHT AND LICENSE

Chiara Orsini, CAIDA, UC San Diego chiara@caida.org

Copyright (C) 2014 The Regents of the University of California.

Statistics::Discrete is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version.

Statistics::Discrete is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.

You should have received a copy of the GNU General Public License along with Statistics::Discrete. If not, see <http://www.gnu.org/licenses/>.