Go to the documentation of this file. 1 #ifndef __JTOOLS__JQUANTILE__
2 #define __JTOOLS__JQUANTILE__
45 const int option = 0) :
65 template<
class iterator_type,
class value_type,
class result_type>
67 iterator_type __begin,
69 result_type value_type::*member,
70 const double w = 1.0) :
74 put(__begin, __end, member,
w);
88 template<
class iterator_type,
class value_type,
class result_type>
90 iterator_type __begin,
92 result_type (value_type::*
function)()
const,
93 const double w = 1.0) :
97 put(__begin, __end,
function,
w);
110 min = +std::numeric_limits<double>::max();
111 max = -std::numeric_limits<double>::max();
123 void put(
const double x,
const double w = 1.0)
133 buffer.insert(std::make_pair(x,
w));
146 template<
class iterator_type,
class value_type,
class result_type>
147 void put(iterator_type __begin,
149 result_type value_type::*member,
150 const double w = 1.0)
152 for (iterator_type i = __begin; i != __end; ++i) {
153 put((*i).*member,
w);
166 template<
class iterator_type,
class value_type,
class result_type>
167 void put(iterator_type __begin,
169 result_type (value_type::*
function)()
const,
170 const double w = 1.0)
172 for (iterator_type i = __begin; i != __end; ++i) {
173 put(((*i).*
function)(),
w);
265 return std::max(fabs(
max), fabs(
min));
288 double getQuantile(
const double Q,
const bool reverse =
false)
const
314 std::ostream&
print(std::ostream& out,
bool lpr =
true)
const
321 out << setw(nc) << left <<
" " <<
' '
322 << setw(10) << left <<
" mean" <<
' '
323 << setw(10) << left <<
" STD" <<
' '
324 << setw(10) << left <<
" deviation" << endl;
327 out << setw(nc) << left <<
getTitle() <<
' '
373 for (T i = __begin; i != __end; ++i) {
Exception for missing value.
This name space includes all other name spaces (except KM3NETDAQ, KM3NET and ANTARES).
bool getLongprint(std::ostream &out)
Get long print option.
Auxiliary class for title.
const std::string & getTitle() const
Get title.
#define THROW(JException_t, A)
Marco for throwing exception with std::ostream compatible message.
Auxiliary data structure for floating point format specification.
Exception for division by zero.