2 * @file AddTaskCentralMCCorr.C
3 * @author Christian Holm Christensen <cholm@dalsgaard.hehi.nbi.dk>
4 * @date Tue Apr 26 09:55:29 2011
8 * @ingroup pwglf_forward_scripts_tasks
13 * Add a Central MC correction generator task to train
18 * @ingroup pwglf_central_mc
21 AddTaskCentralMCCorr(Bool_t eff=false)
23 // --- Load libraries ----------------------------------------------
24 gROOT->LoadClass("AliAODForwardMult", "libPWGLFforward2");
26 // --- Creating the manager and handlers ---------------------------
27 AliAnalysisManager *mgr = AliAnalysisManager::GetAnalysisManager();
28 if (!mgr->GetMCtruthEventHandler()) {
29 Error("AddTaskCentralMCCorr",
30 "No MC input handler defined - cannot continue");
34 // --- Add our task ------------------------------------------------
35 AliCentralMCCorrectionsTask* task =
36 new AliCentralMCCorrectionsTask("CentralCorr");
37 // This has to match the binning used in the AliAODCentralMult
38 // class. Currently, this is set to 20.
39 task->SetNPhiBins(20);
40 task->SetEffectiveCorrection(eff);
41 // task->SetVertexAxis(40, -20., 20.);
43 // --- create containers for input/output --------------------------