51 data->Branch(
"x", &
x,
"x/D");
52 data->Branch(
"y", &
y,
"y/D");
54 for (
Int_t n = 0;
n < nPoints; ++
n) {
55 x = rng.Rndm() * scale;
56 y = offset + rng.Rndm() * scale;
61 data->ResetBranchAddresses();
73void TMVAMinimalClassification()
75 TString outputFilename =
"out.root";
76 TFile *outFile =
new TFile(outputFilename,
"RECREATE");
79 TTree *signalTree = genTree(1000, 0.0, 2.0, 100);
80 TTree *backgroundTree = genTree(1000, 1.0, 2.0, 101);
82 TString factoryOptions =
"AnalysisType=Classification";
92 dataloader.AddBackgroundTree(backgroundTree, 1.0);
95 TCut backgroundCut =
"";
96 TString datasetOptions =
"SplitMode=Random";
97 dataloader.PrepareTrainingAndTestTree(signalCut, backgroundCut, datasetOptions);
113 delete backgroundTree;
A specialized string object used for TTree selections.
A ROOT file is a suite of consecutive data records (TKey instances) with a well defined format.
virtual void Close(Option_t *option="")
Close a file.
This is the main MVA steering class.
This is the base class for the ROOT Random number generators.
A TTree object has a header with a name and a title.