Go to the documentation of this file.
1 #pragma once
2 #include "CAFAna/Cuts/NueCutsSecondAna.h"
5 #include "CAFAna/Core/Binning.h"
6 namespace ana
7 {
9  const Binning customCVN = Binning::Custom({0.5, 0.75, 0.87, 0.95, 1.0});
10  const Binning customEnergy = Binning::Custom ({0., 1., 2., 3., 4.5, 10.});
12 // there are plenty things in fd_plot.C script that depend on the variable order, so add new vars to the end or be careful in fd_plot.C
14  const int kNumVars = 25;
15  const HistDef defs[kNumVars] = {
16  {"4bin_plot", {"Reconstructed neutrino energy (GeV)", kNue2017Binning, kNue2017AnaBin}},
17  {"en", {"Reconstructed neutrino energy (GeV)", Binning::Simple(24, 0, 12), kNueEnergy2017}},
18  {"id_cvne", {"CVN classifier", Binning::Simple(100, 0., 1), kCVNe}},
19  {"id_custom", {"CVN classifier", customCVN, kCVNe}},
20  {"en_custom", {"Reconstructed neutrino energy (GeV)", customEnergy, kNueEnergy2017}},
21  {"shw_e", {"Primary shower calorimetric energy (GeV)", Binning::Simple(40, 0, 10), kShwCalE}},
22  {"vtx_x", {"Vertex X", Binning::Simple(50, -800, +800), kVtxX}},
23  {"vtx_y", {"Vertex Y", Binning::Simple(50, -800, +800), kVtxY}},
24  {"vtx_z", {"Vertex Z", Binning::Simple(50, -100, +6100), kVtxZ}},
25  {"inelast", {"Reconstructed inelasticity", Binning::Simple(30, -0.2, 1.), kInelasticity}},
26  {"had_e_cvn", {"Total CalE of hadronic showers (GeV)", Binning::Simple(20, 0, 5), kCVNhadE}},
27  {"distAllFront",{"Distance of all prongs to the front",Binning::Simple(100, -100, 6000),kDistAllFront}},
28  {"distAllBack",{"Distance of all prongs to the back",Binning::Simple(100, -100, 6000),kDistAllBack}},
29  {"distAllTop",{"Distance of all prongs to the top",Binning::Simple(100, -100, 1600),kDistAllTop}},
30  {"distAllBottom",{"Distance of all prongs to the bottom",Binning::Simple(100, -100, 1600),kDistAllBottom}},
31  {"distAllEast",{"Distance of all prongs to the east",Binning::Simple(100, -100, 1600),kDistAllEast}},
32  {"distAllWest",{"Distance of all prongs to the west",Binning::Simple(100, -100, 1600),kDistAllWest}},
33  {"shwMaxY",{"Maximum y of all start and stop points",Binning::Simple(100, -800, 800),kMaxY}},
34  {"sparsenessAsymm",{"Sparseness asymmetry",Binning::Simple(50, -1, 1),kSparsenessAsymm}},
35  {"shw_Ptp", {"pT/p", Binning::Simple(50, 0., 1.), kPtP}},
36  {"cosmic_bdt", {"Cosmic BDT", Binning::Simple(100, 0, 1), kCosPIDContain}},
37  {"merged_4bin", {"Reconstructed neutrino energy (GeV)", kNue2017BinningMergedPeripheral, kNue2017AnaBinMergedPeripheral}},
38  {"id_cvne_zoom", {"CVN classifier", Binning::Simple(25, 0.75, 1), kCVNe}},
39  {"had_e_2017", {"Hadronic part in reconstructed neutrino energy", Binning::Simple(20, 0, 5), khadE2017}},
40  {"em_e_2017", {"EM part in reconstructed neutrino energy", Binning::Simple(20, 0, 5), kemE2017}},
41  };
43 const int kNumSels = 10;
46  const std::string selNames[kNumSels] = {"PeriHELP", "PeriHEMP", "PeriLP", "PeriMP", "CoreLP", "CoreHE", "Presel", "Core", "Peripheral", "All"};
49 }
const int kNumVars
Definition: vars.h:14
Represent the binning of a Spectrum's x-axis.
Definition: Binning.h:16
Cuts and Vars for the 2020 FD DiF Study.
Definition: vars.h:6
const Var kDistAllBottom([](const caf::SRProxy *sr){if(std::isnan(1.*sr->sel.nuecosrej.distallpngbottom)) return-1000.0f;return float(sr->sel.nuecosrej.distallpngbottom);})
Distance of all showers in slice from the bottom edge of detector.
Definition: NueVars.h:33
const Var kCVNe
Definition: Vars.cxx:35
const Var kDistAllWest([](const caf::SRProxy *sr){if(std::isnan(1.*sr->sel.nuecosrej.distallpngwest)) return-1000.0f;return float(sr->sel.nuecosrej.distallpngwest);})
Distance of all showers in slice from the west edge of detector.
Definition: NueVars.h:36
const Var kDistAllTop([](const caf::SRProxy *sr){if(std::isnan(1.*sr->sel.nuecosrej.distallpngtop)) return-1000.0f;return float(sr->sel.nuecosrej.distallpngtop);})
Distance of all showers in slice from the top edge of detector.
Definition: NueVars.h:30
const Binning customCVN
Definition: vars.h:9
const Var kDistAllBack([](const caf::SRProxy *sr){if(std::isnan(1.*sr->sel.nuecosrej.distallpngback)) return-1000.0f;return float(sr->sel.nuecosrej.distallpngback);})
Distance of all showers in slice from the back edge of detector.
Definition: NueVars.h:42
const Var kShwCalE
const Cut kNue2017BasicPart(kNue2017BasicPartFunc)
const Var kCVNhadE([](const caf::SRProxy *sr){if(!sr->vtx.elastic.IsValid) return-1.0;if(sr->vtx.elastic.fuzzyk.npng< 1) return-1.0;const double calE=sr->slc.calE *CalibrationBugCorrectionFactor(sr->hdr);return std::max(calE-kCVNemE(sr), 0.);})
Definition: NueEnergy2017.h:10
const Cut kNue2017FDPeripheralLPsideband
Definition of the FD peripheral Low PID.
Definition: NueCuts2017.h:195
const Var kCosPIDContain
Definition: NueVars.cxx:110
const Var kemE2017([](const caf::SRProxy *sr){if(!sr->vtx.elastic.IsValid) return-1.0;if(sr->vtx.elastic.fuzzyk.npng< 1) return-1.0;return NueRecoE_2017FDFit(kCVNemE(sr), 0.0);})
Definition: NueVarsExtra.h:42
const Cut kNue2017Presel
Definition: NueCuts2017.h:54
const Cut kNue2017FDHE
FD nue selection for "core" HE sample.
Definition: NueCuts2017.h:238
const Cut kNue2017FD
Full FD nue selection for 2017 analysis.
Definition: NueCuts2017.h:130
const Binning kNue2017Binning
const Var kVtxX
const Cut kNue2017FDPeripheralHELPsideband
Definition of the FD peripheral High Energy Low PID.
Definition: NueCuts2017.h:183
const Cut kNue2017FDLP
FD nue selection for 2017 low PID sideband.
Definition: NueCuts2017.h:247
const Cut kNue2017FDPeripheralHEMPsideband
Definition of the FD peripheral High Energy Mid PID.
Definition: NueCuts2017.h:189
const Var kSparsenessAsymm
Definition: NueVars.cxx:92
const Var kDistAllEast([](const caf::SRProxy *sr){if(std::isnan(1.*sr->sel.nuecosrej.distallpngeast)) return-1000.0f;return float(sr->sel.nuecosrej.distallpngeast);})
Distance of all showers in slice from the east edge of detector.
Definition: NueVars.h:39
const Var kPtP
Transverse momentum fraction in slice.
Definition: NueVars.cxx:90
const Var kNueEnergy2017([](const caf::SRProxy *sr){if(!sr->vtx.elastic.IsValid) return-1.0;if(sr->vtx.elastic.fuzzyk.npng< 1) return-1.0;return NueRecoE_2017FDFit(kCVNemE(sr), kCVNhadE(sr));})
Definition: NueEnergy2017.h:11
const Var kMaxY([](const caf::SRProxy *sr){if(!sr->vtx.elastic.IsValid) return-1000.0f;if(sr->vtx.elastic.fuzzyk.nshwlid==0) return-1000.0f;float maxyall=-999.0;for(unsigned int i=0;i< sr->vtx.elastic.fuzzyk.nshwlid;i++){maxyall=std::max(std::max(sr->vtx.elastic.fuzzyk.png[i].shwlid.start.Y(), sr->vtx.elastic.fuzzyk.png[i].shwlid.stop.Y()), maxyall);}return maxyall;})
Definition: NueVars.h:60
const Cut sels[kNumSels]
Definition: vars.h:44
const Cut kNue2017FDPeripheral
Definition of the FD peripheral sample around our core selected events.
Definition: NueCuts2017.h:152
const HistDef defs[kNumVars]
Definition: vars.h:15
const int kNumSels
Definition: vars.h:43
static Binning Custom(const std::vector< double > &edges)
Definition: Binning.cxx:145
const Var kInelasticity([](const caf::SRProxy *sr){if(!sr->vtx.elastic.IsValid) return 1.f;if(sr->vtx.elastic.fuzzyk.nshwlid< 1) return 1.f;return((sr->slc.calE- sr->vtx.elastic.fuzzyk.png[0].shwlid.calE)/(sr->slc.calE));})
Definition: NueVarsExtra.h:38
const Binning customEnergy
Definition: vars.h:10
const Var kNue2017AnaBin([](const caf::SRProxy *sr){int selBin=kNue2017SelectionBin(sr);float nuE=kNueEnergy2017(sr);int nuEBin=nuE/0.5;assert(nuEBin<=8 &&"An event with nuE > 4.5 should never happen");int anaBin=9 *selBin+nuEBin;return anaBin;})
Definition: NueCuts2017.h:311
const Var kDistAllFront([](const caf::SRProxy *sr){if(std::isnan(1.*sr->sel.nuecosrej.distallpngfront)) return-1000.0f;return float(sr->sel.nuecosrej.distallpngfront);})
Distance of all showers in slice from the front edge of detector.
Definition: NueVars.h:45
const Var kNue2017AnaBinMergedPeripheral([](const caf::SRProxy *sr){int anaBin=kNue2017AnaBin(sr);anaBin=anaBin > 27?29:anaBin;return anaBin;})
Definition: NueCuts2017.h:319
const Var kVtxY
const Cut kNue2017FDPeripheralMPsideband
Definition of the FD peripheral Mid PID.
Definition: NueCuts2017.h:201
const Binning kNue2017BinningMergedPeripheral
const Var kVtxZ
const std::string selNames[kNumSels]
Definition: vars.h:46
static Binning Simple(int n, double lo, double hi, const std::vector< std::string > &labels={})
Definition: Binning.cxx:107
const Var khadE2017([](const caf::SRProxy *sr){if(!sr->vtx.elastic.IsValid) return-1.0;if(sr->vtx.elastic.fuzzyk.npng< 1) return-1.0;return NueRecoE_2017FDFit(0.0, kCVNhadE(sr));})
Definition: NueVarsExtra.h:43
const Cut kNue2017FDAllSamples
Our FD selection including all samples, for making predictions, etc.
Definition: NueCuts2017.h:155
enum BeamMode string