]> git.uio.no Git - u/mrichter/AliRoot.git/blame - PWG4/macros/ConfigAnalysisChargedParticles.C
changed the order of call of endofcycle so that images are produced
[u/mrichter/AliRoot.git] / PWG4 / macros / ConfigAnalysisChargedParticles.C
CommitLineData
fbeaf916 1/* $Id: $ */
2/* $Log$ */
3
4//------------------------------------
5// Configuration macro example:
6//
7// Do some track selection, for input of correlation analysis.
8//
9// Author : Gustavo Conesa Balbastre (INFN-LNF)
10//------------------------------------
11
12AliAnaPartCorrMaker* ConfigAnalysis()
13{
14 //
15 // Configuration goes here
16 //
17 printf("======================== \n");
18 printf("ConfigAnalysis() \n");
19 printf("======================== \n");
20
21
22 //Detector Fidutial Cuts
23 AliFidutialCut * fidCut = new AliFidutialCut();
24 fidCut->DoCTSFidutialCut(kTRUE) ;
25 fidCut->DoEMCALFidutialCut(kFALSE) ;
26 fidCut->DoPHOSFidutialCut(kFALSE) ;
27
28 fidCut->SetSimpleCTSFidutialCut(0.9,0.,360.);
29 fidCut->Print("");
30
31
32 //-----------------------------------------------------------
33 // Reader
34 //-----------------------------------------------------------
35 AliCaloTrackESDReader *reader = new AliCaloTrackESDReader();
36 reader->SetDebug(-1);//10 for lots of messages
37
38 //Switch on or off the detectors information that you want
39 reader->SwitchOffEMCAL();
40 reader->SwitchOffPHOS();
41 reader->SwitchOnCTS(); //We want only tracks
42
43 //Min particle pT
44 reader->SetCTSPtMin(0.2);
45
46 //Uncomment only with MCReader
47// TArrayI statusArray(1) ;
48// statusArray.SetAt(1,0);
49// reader->AddStatusArray(statusArray) ;
50// reader->SwitchOnStatusSelection() ;
51
52 reader->SetFidutialCut(fidCut);
53
1caab52d 54 // //We want tracks fitted in the detectors:
55 // ULong_t status=AliAODTrack::kTPCrefit;
56 // status|=AliAODTrack::kITSrefit; //(default settings)
57
58 // We want tracks whose PID bit is set:
59 // ULong_t status =AliAODTrack::kITSpid;
60 // status|=AliAODTrack::kTPCpid;
61
62 // reader->SetTrackStatus(status);
63
64 //Remove the temporal AODs we create.
08a064bc 65 reader->SwitchOnCleanStdAOD();
1caab52d 66
fbeaf916 67 reader->Print("");
68
69
70 //---------------------------------------------------------------------
71 // Analysis algorithm
72 //---------------------------------------------------------------------
73
74 AliAnaChargedParticles *anatrack = new AliAnaChargedParticles();
75 anatrack->SetDebug(-1);//10 for lots of messages
76 anatrack->SetMinPt(5.);
77 anatrack->SetOutputAODName("Charged");
78 anatrack->SwitchOffFidutialCut();
79 anatrack->SetOutputAODClassName("AliAODPWG4ParticleCorrelation");
80 anatrack->SwitchOnDataMC() ;//Access MC stack and fill more histograms
81 //Set Histrograms bins and ranges
82// anatrack->SetHistoPtRangeAndNBins(0, 50, 100) ;
83// anatrack->SetHistoPhiRangeAndNBins(0, TMath::TwoPi(), 100) ;
84// anatrack->SetHistoEtaRangeAndNBins(-0.7, 0.7, 100) ;
85 anatrack->Print("");
86
87 //---------------------------------------------------------------------
88 // Set analysis algorithm and reader
89 //---------------------------------------------------------------------
90 maker = new AliAnaPartCorrMaker();
91 maker->SetReader(reader);//pointer to reader
92 maker->AddAnalysis(anatrack,0);
93 maker->SetAnaDebug(-1) ;
94 maker->SwitchOnHistogramsMaker() ;
95 maker->SwitchOnAODsMaker() ;
96
97 maker->Print("");
98 //
99 printf("======================== \n");
100 printf("END ConfigAnalysis() \n");
101 printf("======================== \n");
102 return maker ;
103}