CMS 3D CMS Logo

/data/refman/pasoursint/CMSSW_6_1_2_SLHC2_patch1/src/Alignment/OfflineValidation/scripts/comparisonPlots.h

Go to the documentation of this file.
00001 //#include "TMultiGraph.h"
00002 #include "TFile.h"
00003 //#include "TGraph.h"
00004 #include "TCanvas.h"
00005 //#include <vector.h>
00006 //#include "TVectorD.h"
00007 //#include "TVectorD.h"
00008 //#include "TEllipse.h"
00009 //#include "TH1F.h"
00010 //#include "TVector2.h"
00011 #include "TArrow.h"
00012 #include "TPaveText.h"
00013 #include "TFrame.h"
00014 #include "TH1F.h"
00015 //#include "TF1.h"
00016 //#include "TGraph.h"
00017 #include "TLegend.h"
00018 #include "TH1F.h"
00019 #include "TH2F.h"
00020 #include "TProfile.h"
00021 #include "TTree.h"
00022 #include "TCut.h"
00023 
00024 class comparisonPlots
00025         {
00026                 
00027         public:
00028                 comparisonPlots(std::string filename, std::string outputDir, std::string outputFilename = "OUTPUT_comparison.root");
00029                 
00030                 void readTree();
00031                 void plot3x5(TCut Cut, char* dirName, bool savePlot = false, std::string plotName = "plot3x5.eps", bool autolimits = false,int ColorCode = 1);
00032                 void plot3x3Rot(TCut Cut, char* dirName, bool savePlot = false, std::string plotName = "plot3x5.eps", bool autolimits = false,int ColorCode = 1);
00033                 void plot3x5Profile(TCut Cut, char* dirName, int nBins, bool savePlot = false, std::string plotName = "plot3x5Profile.eps", bool autolimits = false,int ColorCode = 1);
00034                 
00035                 void plotTwist(TCut Cut, char* dirName, bool savePlot = false, std::string plotName = "plot3x5.eps", bool autolimits = false,int ColorCode = 1);
00036                 
00037                 float arrowSize;
00038                 void Write();
00039                 TFile* fin;
00040                 TFile* output;
00041                 TTree*  data;
00042                 
00043                 
00044                 
00045         private:
00046                 
00047                 void getMaxMin();
00048                 void getHistMaxMin( TH1* hist, double &max, double &min, int flag );
00049                 
00050                 std::string _outputDir;
00051                 
00052                 //reading tree
00053                 int id_, level_, sublevel_, mid_, mlevel_, useDetId_, detDim_;
00054                 float x_, y_, z_, r_, phi_, alpha_, beta_, gamma_,eta_;
00055                 float dx_, dy_, dz_, dr_, dphi_, dalpha_, dbeta_, dgamma_;
00056                 
00057                 float maxR, minR;
00058                 float maxZ, minZ;
00059                 float maxPhi, minPhi;
00060                 float maxDR, minDR;
00061                 float maxDZ, minDZ;
00062                 float maxRDPhi, minRDPhi;
00063                 float maxDX, minDX;
00064                 float maxDY, minDY;
00065                 
00066                 
00067                 };