Possibility to run over David's trees on Proof
authorbelikov <belikov@f7af4fe6-9843-0410-8265-dc069ae4e863>
Mon, 3 Dec 2012 17:59:58 +0000 (17:59 +0000)
committerbelikov <belikov@f7af4fe6-9843-0410-8265-dc069ae4e863>
Mon, 3 Dec 2012 17:59:58 +0000 (17:59 +0000)
PWGLF/STRANGENESS/LambdaK0PbPb/AliV0CutVariations.C
PWGLF/STRANGENESS/LambdaK0PbPb/AliV0CutVariations.h
PWGLF/STRANGENESS/LambdaK0PbPb/runV0CutVariations.C [new file with mode: 0644]

index 69cd9bc..93ff7a5 100644 (file)
@@ -102,9 +102,9 @@ void AliV0CutVariations::SlaveBegin(TTree * tree)
 
   Init(tree);
 
-  cout<<tree->GetEntries()<<endl;
+  //cout<<tree->GetEntries()<<endl;
 
-   TString option = GetOption();
+  TString option = GetOption();
 
   Int_t    lbins=100;  // number of bins in lt
   Int_t    kbins=33;  // number of bins in pt of Xi
@@ -389,7 +389,7 @@ Bool_t AliV0CutVariations::Process(Long64_t entry)
 
    fChain->GetTree()->GetEntry(entry);
 
-   cout<<entry<<'\r';
+   //cout<<entry<<'\r';
 
    if (fTreeVariableMultiplicity<fCMin) return kFALSE;
    if (fTreeVariableMultiplicity>fCMax) return kFALSE;
index db6a1a6..948f674 100644 (file)
@@ -127,6 +127,7 @@ public :
    virtual void    SlaveTerminate();
    virtual void    Terminate();
 
+  void SetMC(Bool_t isMC=kTRUE) {fIsMC=isMC;}
   Bool_t AcceptV0();
   Bool_t AcceptTracks();
   Bool_t AcceptPID(Int_t code);
@@ -183,7 +184,7 @@ private:
   TH2F* fXiBarM;         //! Mass for anti-Xis
   TH1F* fXiBarSiP;       //! Side-band subtracted Pt for reconstructed anti-Xi
 
-   ClassDef(AliV0CutVariations,0);
+   ClassDef(AliV0CutVariations,1);
 };
 
 #endif
diff --git a/PWGLF/STRANGENESS/LambdaK0PbPb/runV0CutVariations.C b/PWGLF/STRANGENESS/LambdaK0PbPb/runV0CutVariations.C
new file mode 100644 (file)
index 0000000..e7ff650
--- /dev/null
@@ -0,0 +1,19 @@
+void runV0CutVariations(Bool_t isMC=kFALSE) {
+   TProof::Open("");
+
+   TChain *ch=new TChain("chain");
+   ch->SetProof();
+   
+   gProof->Load("AliV0CutVariations.C+");
+   AliV0CutVariations *selector=new AliV0CutVariations();
+   selector->SetMC(isMC);
+
+   if (isMC) {
+     ch->Add("DavidsV0MC_offline.root/PWG2CheckPerformanceLambda_PP_MC/fTree");
+   } else {
+     ch->AddFile("DavidsV0_off.root/PWG2CheckLambda_off_PP/fTree");
+   }
+
+   ch->Process(selector);
+
+}