CMS 3D CMS Logo

/data/refman/pasoursint/CMSSW_5_3_10_patch2/src/RecoTBCalo/HcalPlotter/scripts/PlotAllDisplay.h

Go to the documentation of this file.
00001 #ifndef PLOTALLDISPLAY_H
00002 #define PLOTALLDISPLAY_H
00003 
00004 #include "TFile.h"
00005 #include "TTree.h"
00006 #include "TH1.h"
00007 #include <iostream>
00008 #include "HistoManager.h"
00009 #include "MyHcalClasses.h"
00010 #include "TCanvas.h"
00011 #include "TProfile.h"
00012 
00013 class PlotAllDisplay {
00014 public:
00015   PlotAllDisplay(const char *outfn) : m_f(outfn), histKeys(&m_f)
00016   {
00017     m_movie=0;
00018     n_movie=0;
00019   }
00020   void displaySummary(int ieta=0, int iphi=0, int evtType=4, int flavType=0);
00021   void displayOne(int ieta, int iphi, int depth, int evtType, int flavType);
00022   
00023   void displayElecOne(int fiber,int fiberChan,int crate,int slot,int tb,int evtType, int flavType);
00024   void displayElecSummary(int crate,int Slot,int tb,int evtType4, int flavType);
00025     void displayElecOne(const MyElectronicsId& id, int evtType, int flavType);
00026     void CrateDisplaySelector(int crate, int evtType, int flavType,int plotStatType);
00027 
00028 
00029   void displayOne(const MyHcalDetId& id, int evtType, int flavType);
00030   void displaySelector(int evtType, int flavType, int plotStatType);
00031   MyHcalSubdetector getSubDetector(int ieta, int depth);
00032 private:
00033   struct DisplaySetupStruct {
00034     std::string eventTypeStr;
00035     std::string flavTypeStr;
00036     int ieta, iphi;
00037   };
00038   std::vector<MyHcalDetId> spatialFilter(int ieta, int iphi,
00039                                          const std::vector<MyHcalDetId>& inputs);
00040 TH1* bookMasterHistogram(DisplaySetupStruct& ss,
00041                            const std::string& basename,
00042                            int lo, int hi);
00043  
00044   
00045   
00046   struct DisplayElecSetup {
00047     std::string eventTypeStr;
00048     std::string flavTypeStr;
00049     int fiber,fiberChan,crate,Slot;
00050     int tb;
00051   };
00052   std::vector<MyElectronicsId> electronicsFilter(int fiber,int fiberChan,int crate,int slot,int tb,
00053                                          const std::vector<MyElectronicsId>& inputs);
00054  
00055   
00056 TH1* bookMasterHistogram(DisplayElecSetup& ess,
00057                            const std::string& basename,
00058                            int lo, int hi);
00059 
00060 
00061 
00062   TFile m_f;
00063   HistoManager histKeys;
00064   TCanvas* m_movie;
00065   int n_movie;
00066 };
00067 
00068 #endif