48 TH1F h(
"h",
"h", 1000, -3, 3);
49 h.FillRandom(
"gaus", 50000);
51 for (
Int_t i = 0; i <
N; i++) {
59 printf(
"billw%d : RT=%7.3f s, Cpu=%7.3f s, File size= %9d bytes, CX= %g\n",
61 f.GetCompressionFactor());
69 TIter next(
f.GetListOfKeys());
74 auto hmean =
new TH1F(
"hmean",
"hist mean from keys", 100, 0, 1);
76 while ((key = (
TKey*)next())) {
91 auto h =
new TH1F(
"h",
"h", 1000, -3, 3);
92 h->FillRandom(
"gaus", 50000);
93 auto T =
new TTree(
"T",
"test bill");
94 T->Branch(
"event",
"TH1F", &
h, 64000, 0);
95 for (
Int_t i = 0; i <
N; i++) {
105 printf(
"billtw%d : RT=%7.3f s, Cpu=%7.3f s, File size= %9d bytes, CX= %g\n",
107 f.GetCompressionFactor());
116 auto T =
f.Get<
TTree>(
"T");
118 auto hmeant =
new TH1F(
"hmeant",
"hist mean from tree", 100, 0, 1);
150 printf(
"******************************************************************\n");
152 gROOT->GetVersion(),
gROOT->GetVersionDate(),
gROOT->GetVersionTime());
153 printf(
"******************************************************************\n");
ROOT::Detail::TRangeCast< T, true > TRangeDynCast
TRangeDynCast is an adapter class that allows the typed iteration through a TCollection.
R__EXTERN TRandom * gRandom
R__EXTERN TSystem * gSystem
A ROOT file is an on-disk file, usually with extension .root, that stores objects in a file-system-li...
1-D histogram with a float per channel (see TH1 documentation)
static void AddDirectory(Bool_t add=kTRUE)
Sets the flag controlling the automatic add of histograms in memory.
Book space in a file, create I/O buffers, to fill them, (un)compress them.
virtual TObject * ReadObj()
To read a TObject* from the file.
Double_t Rndm() override
Machine independent random number generator.
virtual const char * UnixPathName(const char *unixpathname)
Convert from a local pathname to a Unix pathname.
virtual TString GetDirName(const char *pathname)
Return the directory name in pathname.
virtual int Unlink(const char *name)
Unlink, i.e.
A TTree represents a columnar dataset.
virtual Int_t SetBranchAddress(const char *bname, void *add, TBranch **ptr=nullptr)
Change branch address, dealing with clone trees properly.