37 static constexpr int Scale = 10;
38 std::cout << (value >= (row * Scale) ?
'*' :
' ');
46 for (
auto bin : axis.GetNormalRange()) {
57void hist001_RHist_basics()
67 std::normal_distribution normal1(5.0, 2.0);
68 for (std::size_t i = 0; i < 1000; i++) {
69 hist1.Fill(normal1(gen));
73 std::cout <<
"hist1 with expected mean = " << normal1.mean() <<
"\n";
79 std::normal_distribution normal2(13.0, 4.0);
80 for (std::size_t i = 0; i < 1500; i++) {
81 hist2.Fill(normal2(gen));
83 std::cout <<
"hist2 with expected mean = " << normal2.mean() <<
"\n";
91 std::cout <<
"hist3 with expected entries = " << (hist1.GetNEntries() + hist2.GetNEntries()) <<
"\n";
A bin index with special values for underflow and overflow bins.
static RBinIndex Overflow()
static RBinIndex Underflow()
A histogram for aggregation of data along multiple dimensions.
double ComputeMean(std::size_t dim=0) const
Compute the arithmetic mean of unbinned values.
double ComputeStdDev(std::size_t dim=0) const
Compute the standard deviation of unbinned values.
const BinContentType & GetBinContent(const std::array< RBinIndex, N > &indices) const
Get the content of a single bin.
const std::vector< RAxisVariant > & GetAxes() const
std::uint64_t GetNEntries() const
A regular axis with equidistant bins in the interval .