Illustrates the advantages of a TH1K histogram
{
for (
Int_t j = 0; j < 3; j++)
c1->GetPad(j+1)->Modified();
}
void hksimple()
{
hpx[0] =
new TH1F(
"hp0",
"Normal histogram",1000,-4,4);
hpx[1] =
new TH1K(
"hk1",
"Nearest Neighbour of order 3",1000,-4,4);
hpx[2] =
new TH1K(
"hk2",
"Nearest Neighbour of order 16",1000,-4,4,16);
for (
Int_t j = 0; j < 3; j++) {
}
for (
Int_t j = 0; j < 3; j++)
}
for (
Int_t j = 0; j < 3; j++)
}
R__EXTERN TRandom * gRandom
R__EXTERN TSystem * gSystem
virtual void SetFillColor(Color_t fcolor)
Set the fill area color.
1-D histogram with a float per channel (see TH1 documentation)
TH1K class supports the nearest K Neighbours method, widely used in cluster analysis.
TH1 is the base class of all histogram classes in ROOT.
void Draw(Option_t *option="") override
Draw this histogram with options.
TFitResultPtr Fit(FitObject *h1, TF1 *f1, Foption_t &option, const ROOT::Math::MinimizerOptions &moption, const char *goption, ROOT::Fit::DataRange &range)
RResultPtr< std::decay_t< T > > Fill(T &&model, const ColumnNames_t &columnList)
Return an object of type T on which T::Fill will be called once per event (lazy action).
- Author
- Victor Perevovchikov
Definition in file hksimple.C.