This structure contains the simplest Descriptives for a set, variable, etc. It includes : More...
#include <statistics.h>
Public Member Functions | |
Descriptives () | |
Default constructor. More... | |
Descriptives (const type &, const type &, const type &, const type &) | |
Values constructor. More... | |
virtual | ~Descriptives () |
Destructor. More... | |
void | set (const type &, const type &, const type &, const type &) |
void | set_minimum (const type &) |
void | set_maximum (const type &) |
void | set_mean (const type &) |
void | set_standard_deviation (const type &) |
Tensor< type, 1 > | to_vector () const |
bool | has_minimum_minus_one_maximum_one () |
bool | has_mean_zero_standard_deviation_one () |
void | save (const string &file_name) const |
void | print (const string &="Descriptives:") const |
Print the tittle of descriptives structure. More... | |
Public Attributes | |
string | name |
Name of variable. More... | |
type | minimum = type(0) |
Smallest value of a set, function, etc. More... | |
type | maximum = type(0) |
Biggest value of a set, function, etc. More... | |
type | mean = type(0) |
Mean value of a set, function, etc. More... | |
type | standard_deviation = type(0) |
Standard deviation value of a set, function, etc. More... | |
This structure contains the simplest Descriptives for a set, variable, etc. It includes :
Definition at line 40 of file statistics.h.
|
explicit |
Default constructor.
Definition at line 16 of file statistics.cpp.
|
explicit |
Values constructor.
Definition at line 28 of file statistics.cpp.
|
virtual |
Destructor.
Definition at line 41 of file statistics.cpp.
bool has_mean_zero_standard_deviation_one | ( | ) |
Returns true if the mean value is 0 and the standard deviation value is 1, and false otherwise.
Definition at line 125 of file statistics.cpp.
bool has_minimum_minus_one_maximum_one | ( | ) |
Returns true if the minimum value is -1 and the maximum value is +1, and false otherwise.
Definition at line 111 of file statistics.cpp.
void print | ( | const string & | title = "Descriptives:" | ) | const |
Print the tittle of descriptives structure.
Definition at line 140 of file statistics.cpp.
void save | ( | const string & | file_name | ) | const |
Saves to a file the minimum, maximum, mean and standard deviation of the descriptives structure.
file_name | Name of descriptives data file. |
Definition at line 181 of file statistics.cpp.
void set | ( | const type & | new_minimum, |
const type & | new_maximum, | ||
const type & | new_mean, | ||
const type & | new_standard_deviation | ||
) |
Definition at line 45 of file statistics.cpp.
void set_maximum | ( | const type & | new_maximum | ) |
Sets a new maximum value in the descriptives structure.
new_maximum | Maximum value. |
Definition at line 67 of file statistics.cpp.
void set_mean | ( | const type & | new_mean | ) |
Sets a new mean value in the descriptives structure.
new_mean | Mean value. |
Definition at line 76 of file statistics.cpp.
void set_minimum | ( | const type & | new_minimum | ) |
Sets a new minimum value in the descriptives structure.
new_minimum | Minimum value. |
Definition at line 58 of file statistics.cpp.
void set_standard_deviation | ( | const type & | new_standard_deviation | ) |
Sets a new standard deviation value in the descriptives structure.
new_standard_deviation | Standard deviation value. |
Definition at line 85 of file statistics.cpp.
Tensor< type, 1 > to_vector | ( | ) | const |
Returns all the statistical parameters contained in a single vector. The size of that vector is four. The elements correspond to the minimum, maximum, mean and standard deviation values respectively.
Definition at line 96 of file statistics.cpp.
type maximum = type(0) |
Biggest value of a set, function, etc.
Definition at line 86 of file statistics.h.
type mean = type(0) |
Mean value of a set, function, etc.
Definition at line 90 of file statistics.h.
type minimum = type(0) |
Smallest value of a set, function, etc.
Definition at line 82 of file statistics.h.
string name |
Name of variable.
Definition at line 78 of file statistics.h.
type standard_deviation = type(0) |
Standard deviation value of a set, function, etc.
Definition at line 94 of file statistics.h.