00001 #ifndef StarterKit_HistoTrack_h
00002 #define StarterKit_HistoTrack_h
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021
00022
00023
00024
00025
00026
00027
00028
00029
00030
00031
00032
00033
00034
00035
00036
00037 #include "PhysicsTools/StarterKit/interface/HistoGroup.h"
00038
00039
00040 #include "DataFormats/RecoCandidate/interface/RecoChargedCandidate.h"
00041
00042
00043
00044 #include <string>
00045 #include <vector>
00046
00047
00048 #include <TH1D.h>
00049
00050 namespace pat {
00051
00052 class HistoTrack : public HistoGroup<reco::RecoChargedCandidate> {
00053
00054 public:
00055 HistoTrack(std::string dir = "track", std::string groupName = "Track", std::string groupLabel = "track",
00056 double pt1=0, double pt2=200, double m1=0, double m2=200,
00057 TFileDirectory * parentDir=0 );
00058 virtual ~HistoTrack() { } ;
00059
00060
00061
00062 virtual void fill( const reco::RecoChargedCandidate *track, uint iPart = 1, double weight = 1.0 );
00063 virtual void fill( const reco::RecoChargedCandidate &track, uint iPart = 1, double weight = 1.0 ) { fill(&track, iPart, weight); }
00064
00065
00066
00067 virtual void fill( const reco::ShallowClonePtrCandidate *track, uint iPart = 1, double weight = 1.0 );
00068 virtual void fill( const reco::ShallowClonePtrCandidate &track, uint iPart = 1, double weight = 1.0 )
00069 { fill(&track, iPart, weight); }
00070
00071 virtual void fillCollection( const std::vector<reco::RecoChargedCandidate> & coll, double weight = 1.0 );
00072
00073
00074 void clearVec();
00075
00076 protected:
00077 PhysVarHisto * h_dxy_ ;
00078 PhysVarHisto * h_dz_ ;
00079 PhysVarHisto * h_nValid_;
00080 PhysVarHisto * h_nLost_;
00081 };
00082 }
00083 #endif