]> git.uio.no Git - u/mrichter/AliRoot.git/commitdiff
- fixed the statistics box printing
authorkkanaki <kkanaki@f7af4fe6-9843-0410-8265-dc069ae4e863>
Sun, 17 Apr 2011 11:31:37 +0000 (11:31 +0000)
committerkkanaki <kkanaki@f7af4fe6-9843-0410-8265-dc069ae4e863>
Sun, 17 Apr 2011 11:31:37 +0000 (11:31 +0000)
HLT/QA/tasks/macros/drawGlobalESDHistograms.C

index dbf3de792eb36d5244cf27075f420467872beab4..c2056e54186adceb370f433625d33ccb46f783af 100644 (file)
@@ -77,7 +77,7 @@ void drawGlobalESDHistograms(const char* filename="HLT-OFFLINE-GLOBAL-comparison
  h1->SetTitle("TPC cluster distribution");
  h1->GetXaxis()->SetTitle("TPC clusters per track");
 
- TLegend *leg1 = new TLegend(0.7,0.6,0.88,0.77);
+ TLegend *leg1 = new TLegend(0.6,0.2,0.8,0.5);
  leg1->SetFillColor(10);
  leg1->SetLineColor(10);
  leg1->AddEntry(h1,"HLT", "l");
@@ -85,7 +85,6 @@ void drawGlobalESDHistograms(const char* filename="HLT-OFFLINE-GLOBAL-comparison
 
  c1->cd(1);
  plot(h1,h2);
- leg1->Draw("same");
 
 //-------------------------------------------------
 
@@ -125,6 +124,7 @@ void drawGlobalESDHistograms(const char* filename="HLT-OFFLINE-GLOBAL-comparison
 
  c1->cd(5);
  plot(h1,h2);
+ leg1->Draw("same");
 
 //------------------------------------------------- 
 
@@ -185,7 +185,6 @@ void printStats(TH1F* h1, TH1F* h2){
   st2->SetY1NDC(st2->GetY2NDC()-TMath::Abs(st1->GetY1NDC()-st1->GetY2NDC()));
   st2->SetLineColor(0);
   st2->SetTextColor(h2->GetLineColor());
-  st2->SetFillStyle(0);
   st2->Draw();  
   return;
 }
@@ -207,9 +206,9 @@ void plot(TH1F *h1, TH1F *h2){
   else xmax = h2->GetBinLowEdge(h2->GetNbinsX()+1);
   
   h2->SetAxisRange(xmin, xmax, "X");  
-  printStats(h1,h2);
   
   h1->Draw();
   h2->Draw("sames");
+  printStats(h1,h2);
   return;
 }