66#include "../test/Event.h"
71 TFile f(
"tree108.root",
"RECREATE");
74 TTree t4(
"t4",
"A Tree with Events");
80 t4.Branch(
"event_split", &event,16000,99);
81 t4.Branch(
"event_not_split", &event,16000,0);
93 event->SetType(etype);
94 event->SetHeader(
ev, 200, 960312,
random);
98 event->SetTemperature(
random + 20.);
139 auto event =
new Event();
143 auto branch =
t4->GetBranch(
"event_split");
144 branch->SetAddress(&event);
154 if (event->GetNtrack() > 587)
158 nb +=
t4->GetEntry(i);
169 if (
gROOT->IsBatch())
#define R__LOAD_LIBRARY(LIBRARY)
ROOT::Detail::TRangeCast< T, true > TRangeDynCast
TRangeDynCast is an adapter class that allows the typed iteration through a TCollection.
R__EXTERN TRandom * gRandom
Using a TBrowser one can browse all ROOT objects.
A ROOT file is an on-disk file, usually with extension .root, that stores objects in a file-system-li...
static TFile * Open(const char *name, Option_t *option="", const char *ftitle="", Int_t compress=ROOT::RCompressionSetting::EDefaults::kUseCompiledDefault, Int_t netopt=0)
Create / open a file.
virtual Double_t Gaus(Double_t mean=0, Double_t sigma=1)
Samples a random number from the standard Normal (Gaussian) Distribution with the given mean and sigm...
Double_t Rndm() override
Machine independent random number generator.
virtual void Rannor(Float_t &a, Float_t &b)
Return 2 numbers distributed following a gaussian with mean=0 and sigma=1.
A TTree represents a columnar dataset.