21namespace Experimental {
97 throw std::invalid_argument(
"nDimensions must be > 0");
118 throw std::invalid_argument(
"number of dimensions not identical in Add");
169 return stats.fSumWX /
fSumW;
196 return stats.fSumWX2 /
fSumW - mean * mean;
246 return (
EWX3 - 3 *
EWX2 * mean + 2 * mean * mean * mean) / std::pow(var, 1.5);
284 return (
EWX4 - 4 *
EWX3 * mean + 6 *
EWX2 * mean * mean - 3 * mean * mean * mean * mean) / (var * var) - 3;
288 template <std::size_t
I,
typename... A>
292 if constexpr (
I + 1 <
sizeof...(A)) {
297 template <std::size_t
I, std::size_t
N,
typename... A>
301 if constexpr (
I + 1 <
N) {
321 template <
typename... A>
322 void Fill(
const std::tuple<A...> &args)
325 throw std::invalid_argument(
"invalid number of arguments to Fill");
346 template <
typename... A>
350 throw std::invalid_argument(
"invalid number of arguments to Fill");
377 template <
typename... A>
380 auto t = std::forward_as_tuple(args...);
382 static constexpr std::size_t
N =
sizeof...(A) - 1;
384 throw std::invalid_argument(
"invalid number of arguments to Fill");
387 double w = std::get<N>(t).fValue;
ROOT::Detail::TRangeCast< T, true > TRangeDynCast
TRangeDynCast is an adapter class that allows the typed iteration through a TCollection.
Option_t Option_t TPoint TPoint const char GetTextMagnitude GetFillStyle GetLineColor GetLineWidth GetMarkerStyle GetTextAlign GetTextColor GetTextSize void char Point_t Rectangle_t WindowAttributes_t Float_t Float_t Float_t Int_t Int_t UInt_t UInt_t Rectangle_t Int_t Int_t Window_t TString Int_t GCValues_t GetPrimarySelectionOwner GetDisplay GetScreen GetColormap GetNativeEvent const char const char dpyName wid window const char font_name cursor keysym reg const char only_if_exist regb h Point_t winding char text const char depth char const char Int_t count const char ColorStruct_t color const char Pixmap_t Pixmap_t PictureAttributes_t attr const char char ret_data h unsigned char height h Atom_t Int_t ULong_t ULong_t unsigned char prop_list Atom_t Atom_t Atom_t Time_t type
Histogram statistics of unbinned values.
void Add(const RHistStats &other)
Add all entries from another statistics object.
void Fill(const std::tuple< A... > &args, RWeight weight)
Fill an entry into this statistics object with a weight.
void FillImpl(const std::tuple< A... > &args)
double ComputeSkewness(std::size_t dim=0) const
Compute the skewness of unbinned values.
void Fill(const A &...args)
Fill an entry into this statistics object.
std::vector< RDimensionStats > fDimensionStats
The sums per dimension.
void Clear()
Clear this statistics object.
void FillImpl(const std::tuple< A... > &args, double w)
double fSumW
The sum of weights.
std::size_t GetNDimensions() const
const RDimensionStats & GetDimensionStats(std::size_t dim=0) const
double fSumW2
The sum of weights squared.
void Fill(const std::tuple< A... > &args)
Fill an entry into this statistics object.
double ComputeNEffectiveEntries() const
Compute the number of effective entries.
double ComputeVariance(std::size_t dim=0) const
Compute the variance of unbinned values.
void Streamer(TBuffer &)
ROOT Streamer function to throw when trying to store an object of this class.
std::uint64_t GetNEntries() const
double ComputeMean(std::size_t dim=0) const
Compute the arithmetic mean of unbinned values.
double ComputeKurtosis(std::size_t dim=0) const
Compute the (excess) kurtosis of unbinned values.
RHistStats(std::size_t nDimensions)
Construct a statistics object.
std::uint64_t fNEntries
The number of entries.
double ComputeStdDev(std::size_t dim=0) const
Compute the standard deviation of unbinned values.
Buffer base class used for serializing objects.
Statistics for one dimension.
void Add(double x, double w)
void Add(const RDimensionStats &other)
A weight for filling histograms.