]> git.uio.no Git - u/mrichter/AliRoot.git/blame - EVE/alice-macros/tpc_hits_eta_split.C
First big commit of the mchview program and its accompanying library,
[u/mrichter/AliRoot.git] / EVE / alice-macros / tpc_hits_eta_split.C
CommitLineData
5a5a1232 1// $Id$
2
f37061fc 3void tpc_hits_eta_split(const char *varexp =
4 "TPC2.fArray.fR:TPC2.fArray.fFi:TPC2.fArray.fZ"
5 ":TPC2.fArray.Eta()",
6 const char *selection = "TPC2.fArray.fR>80")
5a5a1232 7{
8 // Extracts 'major' TPC hits (not the compressed ones).
9 // This gives ~2.5% of all hits.
10
11 AliRunLoader* rl = Alieve::Event::AssertRunLoader();
12 rl->LoadHits("TPC");
13
14 TTree* ht = rl->GetTreeH("TPC", false);
5a5a1232 15
f37061fc 16 Reve::PointSetArray* l = new Reve::PointSetArray("TPC hits - Eta Slices", "");
17 l->SetSourceCS(TPointSelectorConsumer::TVT_RPhiZ);
02fe340a 18 l->SetMarkerColor((Color_t)3);
19 l->SetMarkerStyle(20); // full circle
8a68912d 20 l->SetMarkerSize(.5);
02fe340a 21
5b96ea20 22 gReve->AddRenderElement(l);
23 l->InitBins("Eta", 20, -2, 2);
5a5a1232 24
f37061fc 25 TPointSelector ps(ht, l, varexp, selection);
26 ps.Select();
5a5a1232 27
02fe340a 28 l->CloseBins();
5a5a1232 29
5b96ea20 30 gReve->Redraw3D();
5a5a1232 31}