updated for MC
authorssakai <ssakai@f7af4fe6-9843-0410-8265-dc069ae4e863>
Thu, 7 Jun 2012 15:14:28 +0000 (15:14 +0000)
committerssakai <ssakai@f7af4fe6-9843-0410-8265-dc069ae4e863>
Thu, 7 Jun 2012 15:14:28 +0000 (15:14 +0000)
PWGHF/hfe/macros/AddTaskHFEElecV2.C

index 9faab53..c0c92b8 100644 (file)
@@ -79,5 +79,22 @@ AliAnalysisTask *AddTaskHFEElecV2()
   mgr->ConnectInput(taskTR, 0, cinput);
   mgr->ConnectOutput(taskTR, 1, coutput1);
   
+  if(MCthere){
+    
+    AliAnalysisTaskElecV2 *taskMC = ConfigHFEElecV2(MCthere);
+    mgr->AddTask(taskMC);
+    
+    taskMC->SelectCollisionCandidates(AliVEvent::kMB);
+    
+    TString containerName3 = mgr->GetCommonFileName();
+    containerName3 += ":PWGHF_hfeCalMCV2";
+    
+    AliAnalysisDataContainer *cinput = mgr->GetCommonInputContainer();
+    AliAnalysisDataContainer *coutput1 = mgr->CreateContainer("histMC", TList::Class(),AliAnalysisManager::kOutputContainer, containerName3.Data());
+    mgr->ConnectInput(taskMC, 0, cinput);
+    mgr->ConnectOutput(taskMC, 1, coutput1);
+  }
+  
+  
   return NULL;
 }