CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Groups Pages
HIPplots.h
Go to the documentation of this file.
1 #ifndef HIPPLOTS_H
2 #define HIPPLOTS_H
3 
4 #include <Riostream.h>
5 #include <vector>
6 #include <string>
7 //#include <stdio.h>
8 #include "TFile.h"
9 #include "TH2F.h"
10 #include "TChain.h"
11 #include "TString.h"
12 #include "TCanvas.h"
13 #include "TFileIter.h"
14 #include "TStyle.h"
15 #include "TMath.h"
16 #include "TCut.h"
17 #include "TGraph.h"
18 
19 class HIPplots{
20 public:
21  HIPplots(int IOV, char* path, char* outFile);
22  void extractAlignParams(int i, int minHits = 0, int subDet = 0, int doubleSided = 0);
23  void extractAlignShifts(int i, int minHits = 0, int subDet = 0);
24  void plotAlignParams(string ShiftsOrParams, char* plotName = "test.png");
25  void plotAlignParamsAtIter(int iter, string ShiftsOrParams, char* plotName = "test.png");
26  void plotHitMap(char *outpath, int subDet, int minHits=0);
27  void extractAlignableChiSquare(int minHits=0, int subDet =0, int doubleSided = 0);
28  void plotAlignableChiSquare(char *plotName ="testchi2.png", float minChi2n=-1.0);
29  void extractSurveyResiduals(int currentPar, int subDet =0);
30  void dumpAlignedModules(int nhits=0);
31 
32  int _IOV;
33  TString _path;
34  TString _outFile;
35  TString _inFile_params;
37  TString _inFile_truepos;
38  TString _inFile_alipos;
39  TString _inFile_mispos;
41  TString _inFile_surveys;
42  enum TKdetector_id{ unknown=0, TPBid=1, TPEid=2, TIBid=3, TIDid=4, TOBid=5, TECid=6, ALLid=99 };
43  TLegend * MakeLegend(double x1=0.1, double y1=0.1, double x2=0.1, double y2=0.1);
44  int GetNIterations(TDirectory *f, char *tag, int startingcounter=0);
45  int GetSubDet(unsigned int id);
46  int GetBarrelLayer(unsigned int id);
47  void SetMinMax(TH1* h);
48  int FindPeaks(TH1F *h1, float *peaklist, const int maxNpeaks, int startbin=-1, int endbin=-1);
49  void SetPeakThreshold(float newpeakthreshold);
50  void CheckFiles(int &ierr);
51  bool CheckFileExistence(TString filename);
52  bool CheckHistoRising(TH1D *h);
55 };
56 
57 #endif
TString _inFile_uservars
Definition: HIPplots.h:36
TString _outFile
Definition: HIPplots.h:34
TKdetector_id
Definition: HIPplots.h:42
TString _inFile_surveys
Definition: HIPplots.h:41
bool CheckFileExistence(TString filename)
Definition: HIPplots.cc:1542
void plotAlignParams(string ShiftsOrParams, char *plotName="test.png")
Definition: HIPplots.cc:394
TLegend * MakeLegend(double x1=0.1, double y1=0.1, double x2=0.1, double y2=0.1)
Definition: HIPplots.cc:46
int GetSubDet(unsigned int id)
Definition: HIPplots.cc:1016
TString _inFile_mispos
Definition: HIPplots.h:39
void plotAlignableChiSquare(char *plotName="testchi2.png", float minChi2n=-1.0)
Definition: HIPplots.cc:844
void SetMinMax(TH1 *h)
Definition: HIPplots.cc:1042
int GetBarrelLayer(unsigned int id)
Definition: HIPplots.cc:1033
void CheckFiles(int &ierr)
Definition: HIPplots.cc:1551
void dumpAlignedModules(int nhits=0)
Definition: HIPplots.cc:1490
void extractSurveyResiduals(int currentPar, int subDet=0)
Definition: HIPplots.cc:754
HIPplots(int IOV, char *path, char *outFile)
Definition: HIPplots.cc:20
bool CheckHistoRising(TH1D *h)
Definition: HIPplots.cc:1576
void extractAlignShifts(int i, int minHits=0, int subDet=0)
Definition: HIPplots.cc:199
TString _inFile_params
Definition: HIPplots.h:35
bool plotbadchi2
Definition: HIPplots.h:54
int GetNIterations(TDirectory *f, char *tag, int startingcounter=0)
Definition: HIPplots.cc:1001
void extractAlignableChiSquare(int minHits=0, int subDet=0, int doubleSided=0)
Definition: HIPplots.cc:636
float peakthreshold
Definition: HIPplots.h:53
int _IOV
Definition: HIPplots.h:32
TString _path
Definition: HIPplots.h:33
TString _inFile_alipos
Definition: HIPplots.h:38
TString _inFile_HIPalign
Definition: HIPplots.h:40
void extractAlignParams(int i, int minHits=0, int subDet=0, int doubleSided=0)
Definition: HIPplots.cc:81
void plotAlignParamsAtIter(int iter, string ShiftsOrParams, char *plotName="test.png")
Definition: HIPplots.cc:539
tuple filename
Definition: lut2db_cfg.py:20
TString _inFile_truepos
Definition: HIPplots.h:37
void plotHitMap(char *outpath, int subDet, int minHits=0)
Definition: HIPplots.cc:1062
The Signals That Services Can Subscribe To This is based on ActivityRegistry h
Helper function to determine trigger accepts.
Definition: Activities.doc:4
int FindPeaks(TH1F *h1, float *peaklist, const int maxNpeaks, int startbin=-1, int endbin=-1)
Definition: HIPplots.cc:1498
void SetPeakThreshold(float newpeakthreshold)
Definition: HIPplots.cc:1538