From c7b9deb58d01e05ae0acc15459401b28688bb2fd Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Einar=20El=C3=A9n?= Date: Mon, 27 Nov 2023 17:58:55 +0100 Subject: [PATCH] Format --- DQM/src/DQM/SimObjects.cxx | 11 ++++++----- 1 file changed, 6 insertions(+), 5 deletions(-) diff --git a/DQM/src/DQM/SimObjects.cxx b/DQM/src/DQM/SimObjects.cxx index b47db14dc..a645b34b0 100644 --- a/DQM/src/DQM/SimObjects.cxx +++ b/DQM/src/DQM/SimObjects.cxx @@ -15,7 +15,7 @@ void SimObjects::configure(framework::config::Parameters& ps) { void SimObjects::onProcessStart() { getHistoDirectory(); - std::vector labels = { + std::vector creator_process_labels = { "Unknown", // 0: Unknown "e+ e- -> γγ", // 1: annihil "γ e -> γ e", // 2: compt @@ -82,10 +82,11 @@ void SimObjects::onProcessStart() { histograms_.create("pn_child.children", "Track IDs of Children", 100, 0, 1000); - auto hist { histograms_.get("SimParticles.process") } - for (int i{0}; i < labels.size(); ++i) { - const auto& label{labels[i]}; - hist->GetXaxis()->SetBinLabel(i, label.c_str()); + // Add bin labels to category plots + auto hist{histograms_.get("SimParticles.process")}; + for (int i{0}; i < creator_process_labels.size(); ++i) { + const auto& label{creator_process_labels[i]}; + hist->GetXaxis()->SetBinLabel(i + 1, label.c_str()); } }