ROOTPWA
doPlotWEvts_Kpipi.C
Go to the documentation of this file.
1 void doPlotWEvts_Kpipi(TString evtfile, TString mcfile,
2  TString outfile, TString mass){
3 
4 // gROOT->ProcessLine(".L $ROOTPWA/generators/plotWeightedEvts.C+");
5  gROOT->ProcessLine(".L $ROOTPWA/generators/plotWeightedEvts_Kpipi.C+");
6 
7  TFile* file1=TFile::Open(evtfile,"READ");
8  TFile* file2=TFile::Open(mcfile,"READ");
9  TTree* data=(TTree*)file1->Get("events");
10  TTree* mc=(TTree*)file2->Get("pwevents");
11 
12  if (!data) cout << " no data file found! " << endl;
13  if (!mc) cout << " no mc file found! " << endl;
14 
15  plotWeightedEvts_Kpipi(mc,data,outfile,mass);
16 
17  file1->Close();
18  file2->Close();
19 
20 }