CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
List of all members | Public Member Functions | Public Attributes
HPartVSPhi Class Reference

#include <Histograms.h>

Inheritance diagram for HPartVSPhi:
Histograms

Public Member Functions

virtual void Clear ()
 
void Fill (const reco::Particle::LorentzVector &p4, const double &weight=1.)
 
void Fill (const CLHEP::HepLorentzVector &momentum, const double &weight=1.)
 
 HPartVSPhi (const TString &name)
 
virtual void Write ()
 
 ~HPartVSPhi ()
 
- Public Member Functions inherited from Histograms
void declareHistograms ()
 
virtual void Fill (const reco::Particle::LorentzVector &p1, const reco::Particle::LorentzVector &p2)
 
virtual void Fill (const reco::Particle::LorentzVector &p1, const reco::Particle::LorentzVector &p2, const int charge, const double &weight=1.)
 
virtual void Fill (const CLHEP::HepLorentzVector &momentum1, const CLHEP::HepLorentzVector &momentum2)
 
virtual void Fill (const CLHEP::HepLorentzVector &momentum1, const CLHEP::HepLorentzVector &momentum2, const int charge, const double &weight=1.)
 
virtual void Fill (const CLHEP::HepLorentzVector &p1, const reco::Particle::LorentzVector &p2)
 
virtual void Fill (const reco::Particle::LorentzVector &p4, const int charge, const double &weight=1.)
 
virtual void Fill (const CLHEP::HepLorentzVector &momentum, const int charge, const double &weight=1.)
 
virtual void Fill (const reco::Particle::LorentzVector &p4, const double &resValue, const int charge)
 
virtual void Fill (const reco::Particle::LorentzVector &p4, const double &genValue, const double recValue, const int charge)
 
virtual void Fill (const unsigned int number)
 
virtual void Fill (const reco::Particle::LorentzVector &recoP1, const int charge1, const reco::Particle::LorentzVector &genP1, const reco::Particle::LorentzVector &recoP2, const int charge2, const reco::Particle::LorentzVector &genP2, const double &recoMass, const double &genMass)
 
virtual void Fill (const reco::Particle::LorentzVector &recoP1, const int charge1, const reco::Particle::LorentzVector &recoP2, const int charge2, const double &recoMass, const double &genMass)
 
virtual void Fill (const reco::Particle::LorentzVector &recoP1, const reco::Particle::LorentzVector &genP1, const reco::Particle::LorentzVector &recoP2, const reco::Particle::LorentzVector &genP2)
 
virtual void Fill (const double &x, const double &y)
 
virtual void Fill (const double &x, const double &y, const double &a, const double &b)
 
virtual void Fill (const reco::Particle::LorentzVector &p41, const reco::Particle::LorentzVector &p42, const reco::Particle::LorentzVector &p4Res, const double &weight=1.)
 
virtual void Fill (const CLHEP::HepLorentzVector &momentum1, const CLHEP::HepLorentzVector &momentum2, const CLHEP::HepLorentzVector &momentumRes, const double &weight=1.)
 
void fillEventInfo (int proc, int strk, int ntrkr)
 
void fillRecHistograms (const RecTrack_t &r)
 
void fillSimHistograms (const SimTrack_t &s)
 
void fillVzeroHistograms (const RecVzero_t &r, int part)
 
virtual double Get (const reco::Particle::LorentzVector &recoP1, const TString &covarianceName)
 
virtual TString GetName ()
 
 Histograms ()
 
 Histograms (const TString &name)
 
 Histograms (TFile *outputFile, const TString &name)
 
 Histograms (const edm::ParameterSet &pset)
 
virtual void SetWeight (double weight)
 
void writeHistograms ()
 
virtual ~Histograms ()
 
 ~Histograms ()
 

Public Attributes

TH2F * hMassVSPhi_
 
TProfile * hMassVSPhi_prof_
 
TH2F * hPtVSPhi_
 
TProfile * hPtVSPhi_prof_
 

Additional Inherited Members

- Protected Attributes inherited from Histograms
TDirectory * histoDir_
 
TString name_
 
TFile * outputFile_
 
double theWeight_
 

Detailed Description

Definition at line 601 of file Histograms.h.

Constructor & Destructor Documentation

HPartVSPhi::HPartVSPhi ( const TString &  name)
inline

Definition at line 604 of file Histograms.h.

References hMassVSPhi_prof_, hPtVSPhi_prof_, mergeVDriftHistosByStation::name, and Histograms::name_.

604  {
605  name_ = name;
606 // hPtVSPhi_ = new TH2F (name+"_PtVSPhi", "transverse momentum vs phi angle",
607 // 12, -3.2, 3.2, 200, 0, 200);
608 // hMassVSPhi_ = new TH2F (name+"_MassVSPhi", "mass vs phi angle",
609 // 7, -3.2, 3.2, 40, 70, 110);
610 // hMassVSPhiF_ = new TH2F (name+"_MassVSPhiF", "mass vs phi F",
611 // 7, -3.2, 3.2, 40, 70, 110);
612 // hMassVSPhiWp2_ = new TH2F (name+"_MassVSPhiWp2", "mass vs phi Wp2",
613 // 7, -3.2, 3.2, 40, 70, 110);
614 // hMassVSPhiWp1_ = new TH2F (name+"_MassVSPhiWp1", "mass vs phi Wp1",
615 // 7, -3.2, 3.2, 40, 70, 110);
616 // hMassVSPhiW0_ = new TH2F (name+"_MassVSPhiW0", "mass vs phi W0",
617 // 7, -3.2, 3.2, 40, 70, 110);
618 // hMassVSPhiWm1_ = new TH2F (name+"_MassVSPhiWm1", "mass vs phi Wm1",
619 // 7, -3.2, 3.2, 40, 70, 110);
620 // hMassVSPhiWm2_ = new TH2F (name+"_MassVSPhiWm2", "mass vs phi Wm2",
621 // 7, -3.2, 3.2, 40, 70, 110);
622 // hMassVSPhiB_ = new TH2F (name+"_MassVSPhiB", "mass vs phi B",
623 // 7, -3.2, 3.2, 40, 70, 110);
624 
625  // TD profile histograms
626  hMassVSPhi_prof_ = new TProfile (name+"_MassVSPhi_prof", "mass vs phi angle",
627  16, -3.2, 3.2, 70, 110);
628  hPtVSPhi_prof_ = new TProfile (name+"_PtVSPhi_prof", "pt vs phi angle",
629  16, -3.2, 3.2, 0, 200);
630  }
TProfile * hMassVSPhi_prof_
Definition: Histograms.h:732
TProfile * hPtVSPhi_prof_
Definition: Histograms.h:733
TString name_
Definition: Histograms.h:124
HPartVSPhi::~HPartVSPhi ( )
inline

Definition at line 632 of file Histograms.h.

References hMassVSPhi_, hMassVSPhi_prof_, hPtVSPhi_, and hPtVSPhi_prof_.

632  {
633  delete hPtVSPhi_;
634  delete hMassVSPhi_;
635  delete hMassVSPhi_prof_;
636  delete hPtVSPhi_prof_;
637 
638  // delete hMassVSPhiB_;
639 // delete hMassVSPhiWm2_;
640 // delete hMassVSPhiWm1_;
641 // delete hMassVSPhiW0_;
642 // delete hMassVSPhiWp1_;
643 // delete hMassVSPhiWp2_;
644 // delete hMassVSPhiF_;
645  }
TProfile * hMassVSPhi_prof_
Definition: Histograms.h:732
TH2F * hPtVSPhi_
Definition: Histograms.h:730
TProfile * hPtVSPhi_prof_
Definition: Histograms.h:733
TH2F * hMassVSPhi_
Definition: Histograms.h:731

Member Function Documentation

virtual void HPartVSPhi::Clear ( )
inlinevirtual

Implements Histograms.

Definition at line 714 of file Histograms.h.

References hMassVSPhi_, hMassVSPhi_prof_, hPtVSPhi_, and hPtVSPhi_prof_.

714  {
715  hPtVSPhi_->Clear();
716  hMassVSPhi_->Clear();
717  hPtVSPhi_prof_->Clear();
718  hMassVSPhi_prof_->Clear();
719 
720 // hMassVSPhiB_->Clear();
721 // hMassVSPhiWm2_->Clear();
722 // hMassVSPhiWm1_->Clear();
723 // hMassVSPhiW0_->Clear();
724 // hMassVSPhiWp1_->Clear();
725 // hMassVSPhiWp2_->Clear();
726 // hMassVSPhiF_->Clear();
727  }
TProfile * hMassVSPhi_prof_
Definition: Histograms.h:732
TH2F * hPtVSPhi_
Definition: Histograms.h:730
TProfile * hPtVSPhi_prof_
Definition: Histograms.h:733
TH2F * hMassVSPhi_
Definition: Histograms.h:731
void HPartVSPhi::Fill ( const reco::Particle::LorentzVector p4,
const double &  weight = 1. 
)
inlinevirtual

Reimplemented from Histograms.

Definition at line 647 of file Histograms.h.

References CommonMethods::weight().

647  {
648  Fill(CLHEP::HepLorentzVector(p4.x(),p4.y(),p4.z(),p4.t()), weight);
649  }
double p4[4]
Definition: TauolaWrapper.h:92
void Fill(const reco::Particle::LorentzVector &p4, const double &weight=1.)
Definition: Histograms.h:647
void HPartVSPhi::Fill ( const CLHEP::HepLorentzVector &  momentum,
const double &  weight = 1. 
)
inlinevirtual

Reimplemented from Histograms.

Definition at line 651 of file Histograms.h.

References hMassVSPhi_, hMassVSPhi_prof_, hPtVSPhi_, hPtVSPhi_prof_, and CommonMethods::weight().

651  {
652  hPtVSPhi_->Fill(momentum.phi(),momentum.perp(), weight);
653  hMassVSPhi_->Fill(momentum.phi(),momentum.m(), weight);
654  hMassVSPhi_prof_->Fill(momentum.phi(),momentum.m(), weight);
655  hPtVSPhi_prof_->Fill(momentum.phi(),momentum.perp(), weight);
656 
657 // if (momentum.eta()<-1.2) hMassVSPhiB_->Fill(momentum.phi(),momentum.m(), weight);
658 // else if (momentum.eta()<-0.8 && momentum.eta()>-1.2) hMassVSPhiWm2_->Fill(momentum.phi(),momentum.m(), weight);
659 // else if (momentum.eta()<-0.3 && momentum.eta()>-0.8) hMassVSPhiWm1_->Fill(momentum.phi(),momentum.m(), weight);
660 // else if ((fabs(momentum.eta())) < 0.3) hMassVSPhiW0_->Fill(momentum.phi(),momentum.m(), weight);
661 // else if (momentum.eta()>0.3 && momentum.eta()<0.8) hMassVSPhiWp1_->Fill(momentum.phi(),momentum.m(), weight);
662 // else if (momentum.eta()>0.8 && momentum.eta()<1.2) hMassVSPhiWp2_->Fill(momentum.phi(),momentum.m(), weight);
663 // else if (momentum.eta()>1.2) hMassVSPhiF_->Fill(momentum.phi(),momentum.m(), weight);
664  }
TProfile * hMassVSPhi_prof_
Definition: Histograms.h:732
TH2F * hPtVSPhi_
Definition: Histograms.h:730
TProfile * hPtVSPhi_prof_
Definition: Histograms.h:733
TH2F * hMassVSPhi_
Definition: Histograms.h:731
virtual void HPartVSPhi::Write ( )
inlinevirtual

Implements Histograms.

Definition at line 666 of file Histograms.h.

References hMassVSPhi_, hMassVSPhi_prof_, hPtVSPhi_, and hPtVSPhi_prof_.

666  {
667  hPtVSPhi_->Write();
668  hMassVSPhi_->Write();
669  hMassVSPhi_prof_->Write();
670  hPtVSPhi_prof_->Write();
671 
672  // hMassVSPhiB_->Write();
673 // hMassVSPhiWm2_->Write();
674 // hMassVSPhiWm1_->Write();
675 // hMassVSPhiW0_->Write();
676 // hMassVSPhiWp1_->Write();
677 // hMassVSPhiWp2_->Write();
678 // hMassVSPhiF_->Write();
679 
680 // std::vector<TGraphErrors*> graphs ((MuScleFitUtils::fitMass(hMassVSPhi_)));
681 // for(std::vector<TGraphErrors*>::const_iterator graph = graphs.begin(); graph != graphs.end(); graph++){
682 // (*graph)->Write();
683 // }
684 // std::vector<TGraphErrors*> graphsB ((MuScleFitUtils::fitMass(hMassVSPhiB_)));
685 // for(std::vector<TGraphErrors*>::const_iterator graph = graphsB.begin(); graph != graphsB.end(); graph++){
686 // (*graph)->Write();
687 // }
688 // std::vector<TGraphErrors*> graphsWm2 ((MuScleFitUtils::fitMass(hMassVSPhiWm2_)));
689 // for(std::vector<TGraphErrors*>::const_iterator graph = graphsWm2.begin(); graph != graphsWm2.end(); graph++){
690 // (*graph)->Write();
691 // }
692 // std::vector<TGraphErrors*> graphsWm1 ((MuScleFitUtils::fitMass(hMassVSPhiWm1_)));
693 // for(std::vector<TGraphErrors*>::const_iterator graph = graphsWm1.begin(); graph != graphsWm1.end(); graph++){
694 // (*graph)->Write();
695 // }
696 // std::vector<TGraphErrors*> graphsW0 ((MuScleFitUtils::fitMass(hMassVSPhiW0_)));
697 // for(std::vector<TGraphErrors*>::const_iterator graph = graphsW0.begin(); graph != graphsW0.end(); graph++){
698 // (*graph)->Write();
699 // }
700 // std::vector<TGraphErrors*> graphsWp1 ((MuScleFitUtils::fitMass(hMassVSPhiWp1_)));
701 // for(std::vector<TGraphErrors*>::const_iterator graph = graphsWp1.begin(); graph != graphsWp1.end(); graph++){
702 // (*graph)->Write();
703 // }
704 // std::vector<TGraphErrors*> graphsWp2 ((MuScleFitUtils::fitMass(hMassVSPhiWp2_)));
705 // for(std::vector<TGraphErrors*>::const_iterator graph = graphsWp2.begin(); graph != graphsWp2.end(); graph++){
706 // (*graph)->Write();
707 // }
708 // std::vector<TGraphErrors*> graphsF ((MuScleFitUtils::fitMass(hMassVSPhiF_)));
709 // for(std::vector<TGraphErrors*>::const_iterator graph = graphsF.begin(); graph != graphsF.end(); graph++){
710 // (*graph)->Write();
711 // }
712  }
TProfile * hMassVSPhi_prof_
Definition: Histograms.h:732
TH2F * hPtVSPhi_
Definition: Histograms.h:730
TProfile * hPtVSPhi_prof_
Definition: Histograms.h:733
TH2F * hMassVSPhi_
Definition: Histograms.h:731

Member Data Documentation

TH2F* HPartVSPhi::hMassVSPhi_

Definition at line 731 of file Histograms.h.

Referenced by Clear(), Fill(), Write(), and ~HPartVSPhi().

TProfile* HPartVSPhi::hMassVSPhi_prof_

Definition at line 732 of file Histograms.h.

Referenced by Clear(), Fill(), HPartVSPhi(), Write(), and ~HPartVSPhi().

TH2F* HPartVSPhi::hPtVSPhi_

Definition at line 730 of file Histograms.h.

Referenced by Clear(), Fill(), Write(), and ~HPartVSPhi().

TProfile* HPartVSPhi::hPtVSPhi_prof_

Definition at line 733 of file Histograms.h.

Referenced by Clear(), Fill(), HPartVSPhi(), Write(), and ~HPartVSPhi().