25 #include "__subsys__/__pkgname__/plugins/__class__.h"
29 @example_track#
include "DataFormats/TrackReco/interface/Track.h"
33 @example_trackconst
char*
const kPt =
"pt";
48 @example_track
h_pt =
new TH1F(
kPt,
"P_t", 100, 0, 100);
49 @example_track out.Add(h_pt);
62 @example_track
h_pt->Fill(itTrack->pt());
95 auto canvas = std::make_unique<TCanvas>();
107 @example_track TObject*
hist = fromWorkers.FindObject(
kPt);
108 @example_track
if (
nullptr != hist) {
109 @example_track hist->Draw();
110 @example_track
canvas->SaveAs(
"pt.jpg");
111 @example_track }
else {
112 @example_track
cout <<
"no '" <<
kPt <<
"' histogram" << endl;
void process(const edm::Event &iEvent)
std::vector< Track > TrackCollection
collection of Tracks
example_track TH1F * h_pt
auto const & tracks
cannot be loose
example_track example_trackconst char *const kPt
bool getByLabel(InputTag const &tag, Handle< PROD > &result) const
void postProcess(TList &)
bool include(const CollT &coll, const ItemT &item)
__class__Worker(const TList *, TList &)