Main Page | Class Hierarchy | Class List | File List | Class Members

Stat Class Reference

Utility static class containing statistical functions. More...

#include <stat.h>

Inheritance diagram for Stat:

Object List of all members.

Public Member Functions

 Stat ()
 Default constructor. Invoked once. Does nothing.

 ~Stat ()
 Distructor. Does nothing.


Static Public Member Functions

double confInterval (bool &valid, const std::vector< sample_t > &samples, double cl)
 Return the confidence interval of a set of samples.

double mean (bool &valid, const std::vector< sample_t > &samples)
 Return the mean of a set of samples.


Static Private Member Functions

double t_student (double cl, int df)
 Function to access the t-student table.


Static Private Attributes

double t_table [30][4]
 Static table containing the t-student values.


Detailed Description

Utility static class containing statistical functions.

project: measure filename: stat.h author: C. Cicconetti <c.cicconetti@iet.unipi.it> year: 2006 affiliation: Dipartimento di Ingegneria dell'Informazione University of Pisa, Italy description: statistical classes and functions


Member Function Documentation

double Stat::confInterval bool &  valid,
const std::vector< sample_t > &  samples,
double  cl
[static]
 

Return the confidence interval of a set of samples.

The validity bit is false if the number of samples is smaller than or equal to 1, or if the confidence level is outside [0, 1].

double Stat::mean bool &  valid,
const std::vector< sample_t > &  samples
[static]
 

Return the mean of a set of samples.

The validity bit is false if the number of samples is zero.

double Stat::t_student double  cl,
int  df
[static, private]
 

Function to access the t-student table.

Access to the t-student table through the number of degrees of freedom and the confidence level. Return -1.0 if the the number of the degrees of freedom is smaller than or equal to 1, or if the confidence level is outside [0, 1].


Member Data Documentation

double Stat::t_table [static, private]
 

Static table containing the t-student values.

project: measure filename: stat.cc author: C. Cicconetti <c.cicconetti@iet.unipi.it> year: 2006 affiliation: Dipartimento di Ingegneria dell'Informazione University of Pisa, Italy description: body of statistical functions and classes


The documentation for this class was generated from the following files:
Generated on Tue May 30 08:09:56 2006 for ns2measure by doxygen 1.3.7