Attempt to monitor what file is read and merged by what job
[u/mrichter/AliRoot.git] / PWGCF / EBYE / LRC / Test / TestPtN.C
CommitLineData
d03e5de4 1{\r
2 gSystem->Load("libPWG2LRC.so");\r
3 TH1D *gaus = new TH1D("source","source hist",1000,-5,5);\r
4 gaus->FillRandom("gaus",10000);\r
5 TH2D *source = new TH2D("PtN","PtN Test",100,0,100,100,0,5);\r
6 TH2D *err = new TH2D("err","errl hist",100,0,100,100,0,1);\r
7 Double_t x, y;\r
8 for (Int_t i=0;i<10000;i++) \r
9 { \r
10 x = 10 * (gaus->GetRandom() + 5);\r
11 y = 0.678 * (x/20.0 + gaus->GetRandom());\r
12 //Create source 2D histogram with correlation coefficient 0.678\r
13 source->Fill(x,y);\r
14 err->Fill(x,1/x);\r
15 }\r
16 //Create TNN class encapsulated NN correlation algorithms\r
17 //2D histogram pass into TNN constructor\r
18 AliLRCPtN final1("name", source, 0.35, err);\r
19\r
20 TCanvas *c1 = new TCanvas("c1","c1",800,1000);\r
21 c1->Divide(3);\r
22 c1->cd(1);\r
23 source->Draw();\r
24 c1->cd(2);\r
25 final1.Draw_abs();\r
26 c1->cd(3);\r
27 final1.Draw_rel();\r
28 c1->cd();\r
29\r
30 AliLRCPtN final2;\r
31 final2.MakeHistogramm("name", source, 0.35, err);\r
32\r
33 TCanvas *c2 = new TCanvas("c2","c2",800,1000);\r
34 c2->Divide(3);\r
35 c2->cd(1);\r
36 source->Draw();\r
37 c2->cd(2);\r
38 final2.Draw_abs();\r
39 c2->cd(3);\r
40 final2.Draw_rel();\r
41 c2->cd();\r
42\r
43}