28 #include <rdbxx/RDB.h> 45 RdbStats( RDB& irdbtable,
const std::string& name );
55 virtual void normalize_results(
const double norm );
57 virtual void set_output_columns( RDB& ordbtable );
65 RDBColumn* input_column;
68 std::vector<RDBColumn*> output_stats;
72 enum Stats { AVG, MAX, MIN, SD, SUM, SUM2, SUM_T };
76 std::string column_name;
78 double the_statistics[ 7 ];
87 std::string to_string( std::vector<T> values ) {
91 bool first_elem =
true;
92 for (
const auto& value : values ) {
The base class to calculate : average, maximum, minimum, num, stddev and sum.
double get_absolute_average() const
To get the absolute value of the average.
virtual void update_statistics()
Read the column from RDB++, update the statistics for the column.
virtual int calculate_statistics()
Perform the final statistic for the set.