CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
ErrorsPropagationAnalyzer.h
Go to the documentation of this file.
1 #ifndef ERRORSANALYZER_HH
2 #define ERRORSANALYZER_HH
3 
4 // -*- C++ -*-
5 //
6 // Package: ErrorsPropagationAnalyzer
7 // Class: ErrorsPropagationAnalyzer
8 //
16 //
17 // Original Author: Marco De Mattia
18 // Created: Thu Sep 11 12:16:00 CEST 2008
19 // $Id: ErrorsPropagationAnalyzer.h,v 1.4 2012/12/20 16:09:21 emiglior Exp $
20 //
21 //
22 
23 // system include files
24 #include <memory>
25 #include <string>
26 #include <vector>
27 
33 
34 #include <TH1D.h>
35 #include <TProfile.h>
36 #include <TString.h>
37 #include <TCanvas.h>
38 #include <TGraphAsymmErrors.h>
39 #include <TROOT.h>
40 
43 #include "MuScleFitUtils.h"
45 
46 //
47 // class declaration
48 //
49 
51 {
52 public:
55 
56 private:
57  virtual void analyze(const edm::Event&, const edm::EventSetup&);
58  void fillHistograms();
59  void drawHistograms(const TProfile* histo, const TProfile* histoPlusErr,
60  const TProfile* histoMinusErr, const TString& type, const TString& yLabel);
61  void fillValueError();
62  virtual void endJob() {};
64  double massResolution( const lorentzVector& mu1,
65  const lorentzVector& mu2,
66  const std::vector<double> & parval,
67  const double & sigmaPt1,
68  const double & sigmaPt2 );
69  double massResolution( const lorentzVector& mu1,
70  const lorentzVector& mu2,
71  double* parval,
72  const double & sigmaPt1,
73  const double & sigmaPt2);
74 
75  TString treeFileName_;
77  uint32_t maxEvents_;
78  TString outputFileName_;
79  int ptBins_;
80  double ptMin_;
81  double ptMax_;
82  int etaBins_;
83  double etaMin_;
84  double etaMax_;
85  bool debug_;
86 
88 
89  std::vector<double> parameters_;
90  std::vector<double> errors_;
91  std::vector<int> errorFactors_;
92 
93  std::vector<double> valuePlusError_;
94  std::vector<double> valueMinusError_;
95 
96  TProfile * sigmaPtVsEta_;
99 
100  TProfile * sigmaPtVsPt_;
103 
104  TProfile * sigmaPtVsEtaDiff_;
105  TProfile * sigmaPtVsPtDiff_;
106 
107  // Mass resolution
108  TProfile * sigmaMassVsEta_;
111 
112  TProfile * sigmaMassVsPt_;
115 
119 
123 };
124 
125 #endif // RESOLUTIONANALYZER_HH
type
Definition: HCALResponse.h:22
std::vector< double > valueMinusError_
std::vector< double > valuePlusError_
reco::Particle::LorentzVector lorentzVector
Definition: GenMuonPair.h:9
double massResolution(const lorentzVector &mu1, const lorentzVector &mu2, const std::vector< double > &parval, const double &sigmaPt1, const double &sigmaPt2)
Modified method to take into account the error.
void drawHistograms(const TProfile *histo, const TProfile *histoPlusErr, const TProfile *histoMinusErr, const TString &type, const TString &yLabel)
virtual void analyze(const edm::Event &, const edm::EventSetup &)
ErrorsPropagationAnalyzer(const edm::ParameterSet &)