...one of the most highly
regarded and expertly designed C++ library projects in the
world.

— Herb Sutter and Andrei
Alexandrescu, C++
Coding Standards

boost::accumulators::impl::tail_quantile_impl — Tail quantile estimation based on order statistics (for both left and right tails).

// In header: <boost/accumulators/statistics/tail_quantile.hpp>template<typenameSample,typenameLeftRight>structtail_quantile_impl {// typestypedefSample result_type;// construct/copy/destructtail_quantile_impl(dont_care);// public member functionstemplate<typenameArgs> result_type result(Argsconst&)const; };

The estimation of a tail quantile with level based on order statistics requires the chaching of at least the smallest or the largest samples, being the total number of samples. The largest of the smallest samples or the smallest of the largest samples provides an estimate for the quantile: