Hall-D Software  alpha
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
PS_PSC_coinc.C
Go to the documentation of this file.
1 // The following are special comments used by RootSpy to know
2 // which histograms to fetch for the macro.
3 //
4 
5 // hnamepath: /PSPair/PSC_PS/PS_PSIDLeftVsPSCIDLeft
6 // hnamepath: /PSPair/PSC_PS/PS_PSIDRightVsPSCIDRight
7 // hnamepath: /PSPair/PSC_PS/PS_ElVsPSCIDLeft
8 // hnamepath: /PSPair/PSC_PS/PS_ErVsPSCIDRight
9 
10 {
11  TDirectory *dir = (TDirectory*)gDirectory->FindObjectAny("PSPair");
12  if(dir) dir->cd();
13 
14  TH2I* id_LL =(TH2I*)gDirectory->Get("PSC_PS/PS_PSIDLeftVsPSCIDLeft");
15  TH2I* id_RR =(TH2I*)gDirectory->Get("PSC_PS/PS_PSIDRightVsPSCIDRight");
16  TH2I* Eid_LL =(TH2I*)gDirectory->Get("PSC_PS/PS_ElVsPSCIDLeft");
17  TH2I* Eid_RR =(TH2I*)gDirectory->Get("PSC_PS/PS_ErVsPSCIDRight");
18 
19  if(gPad == NULL){
20  TCanvas *c1 = new TCanvas("c1","PS/PSC Geometrical Coincidence Monitor",150,10,990,660);
21  c1->cd(0);
22  c1->Draw();
23  c1->Update();
24  }
25 
26  if(!gPad) return;
27  TCanvas* c1 = gPad->GetCanvas();
28  c1->Divide(2,2);
29 
30  double tsize = 0.0475;
31  gStyle->SetOptStat("emr");
32  if (id_LL){
33  c1->cd(3);
34  id_LL->SetTitleSize(tsize,"xy");
35  id_LL->Draw();
36  }
37  if (id_RR) {
38  c1->cd(4);
39  id_RR->SetTitleSize(tsize,"xy");
40  id_RR->Draw();
41  }
42  if (Eid_LL){
43  c1->cd(1);
44  Eid_LL->SetTitleSize(tsize,"xy");
45  Eid_LL->Draw();
46  }
47  if (Eid_RR) {
48  c1->cd(2);
49  Eid_RR->SetTitleSize(tsize,"xy");
50  Eid_RR->Draw();
51  }
52 
53 }
double tsize
Definition: DIRC_digihit.C:36
Double_t c1[2][NMODULES]
Definition: tw_corr.C:68
TDirectory * dir
Definition: bcal_hist_eff.C:31