Public Member Functions | Private Attributes | List of all members
ana::MECDoubleGaussEnhSystNux Class Reference

#include "/cvmfs/nova-development.opensciencegrid.org/novasoft/releases/N20-12-02/NuXAna/Systs/MECSystsNux.h"

Inheritance diagram for ana::MECDoubleGaussEnhSystNux:
ana::ISyst

Public Member Functions

 MECDoubleGaussEnhSystNux (const MECDoubleGaussEnhParamNux &shift_param, const std::string &shift_param_name)
 
void Shift (double sigma, caf::SRProxy *sr, double &weight) const override
 Perform the systematic shift. More...
 
virtual const std::stringShortName () const final
 The name printed out to the screen. More...
 
virtual const std::stringLatexName () const final
 The name used on plots (ROOT's TLatex syntax) More...
 
virtual void TruthShift (double sigma, caf::SRNeutrinoProxy *nu, double &weight) const
 
virtual bool IsGenieReweight () const
 GENIE reweights can only provide +/-1,2sigma. More...
 

Private Attributes

const MECDoubleGaussEnhParamNux fShiftParam
 

Detailed Description

Definition at line 273 of file MECSystsNux.h.

Constructor & Destructor Documentation

ana::MECDoubleGaussEnhSystNux::MECDoubleGaussEnhSystNux ( const MECDoubleGaussEnhParamNux shift_param,
const std::string shift_param_name 
)
inline

Definition at line 276 of file MECSystsNux.h.

277  : ISyst( "MECDoubleGaussEnhSystNux" + shift_param_name, "MEC 2D Gauss Syst " + shift_param_name ),
278  fShiftParam( shift_param )
279  {}
const MECDoubleGaussEnhParamNux fShiftParam
Definition: MECSystsNux.h:297
ISyst(const std::string &shortName, const std::string &latexName)
Definition: ISyst.cxx:10

Member Function Documentation

virtual bool ana::ISyst::IsGenieReweight ( ) const
inlinevirtualinherited

GENIE reweights can only provide +/-1,2sigma.

Reimplemented in ana::SummedSyst.

Definition at line 56 of file ISyst.h.

56 {return false;}
virtual const std::string& ana::ISyst::LatexName ( ) const
inlinefinalvirtualinherited

The name used on plots (ROOT's TLatex syntax)

Definition at line 30 of file ISyst.h.

References ana::ISyst::fLatexName, ana::ISyst::Shift(), sigma(), sr, and ana::weight.

Referenced by ana::PredictionInterp::DebugPlotColz(), GetGENIEShiftLabels(), ana::NuISyst::SaveTo(), SystsGENIEAna(), and WriteSystName().

30 {return fLatexName;}
std::string fLatexName
Definition: ISyst.h:60
void ana::MECDoubleGaussEnhSystNux::Shift ( double  sigma,
caf::SRProxy sr,
double &  weight 
) const
inlineoverridevirtual

Perform the systematic shift.

Override this function if your systematic depends on non-SRNeutrino quantities. If it is SRNeutrino-only, implement the other function, and let this default forward to you when necessary.

Parameters
sigmaNumber of sigma to shift record by
srThe record to inspect and alter
weightScale this weight for reweighting systematics

Reimplemented from ana::ISyst.

Definition at line 281 of file MECSystsNux.h.

References ana::CalcMECDoubleGaussEnhNux(), fShiftParam, ana::kIsNue, ana::kIsNumuCC(), caf::kMEC, ana::kTrueQ0, ana::kTrueQ3, caf::Proxy< caf::StandardRecord >::mc, and caf::Proxy< caf::SRTruthBranch >::nu.

282  {
283  //This will need to be expanded when we have NC MEC Events in the new processing.
284  if( (kIsNumuCC( sr ) || kIsNue( sr)) && sr->mc.nu[0].mode == caf::kMEC ){
285  double q0 = kTrueQ0( sr );
286  double q3 = kTrueQ3( sr );
287 
288  double wgt_nominal = CalcMECDoubleGaussEnhNux( q0, q3, fShiftParam, 0 );
289  double wgt_shift = CalcMECDoubleGaussEnhNux( q0, q3, fShiftParam, sigma );
290 
291  weight *= wgt_shift / wgt_nominal;
292  }
293  else return;
294  }
const Cut kIsNumuCC(CCFlavSel(14, 14))
Select CC .
const Var weight
caf::Proxy< std::vector< caf::SRNeutrino > > nu
Definition: SRProxy.h:618
const Var kTrueQ0
Definition: TruthVars.h:32
double CalcMECDoubleGaussEnhNux(const double q0, const double q3, const MECDoubleGaussEnhParamNux shift_param, const double shift_sigma)
Definition: MECSystsNux.h:21
const Var kTrueQ3
Definition: TruthVars.h:38
const Cut kIsNue([](const caf::SRProxy *sr){return(sr->mc.nnu==1 &&abs(sr->mc.nu[0].pdg)==12);})
Definition: TruthCuts.h:9
double sigma(TH1F *hist, double percentile)
caf::Proxy< caf::SRTruthBranch > mc
Definition: SRProxy.h:2138
const MECDoubleGaussEnhParamNux fShiftParam
Definition: MECSystsNux.h:297
virtual const std::string& ana::ISyst::ShortName ( ) const
inlinefinalvirtualinherited
virtual void ana::ISyst::TruthShift ( double  sigma,
caf::SRNeutrinoProxy nu,
double &  weight 
) const
inlinevirtualinherited

For systematics that deal only with the neutrino truth and not any reconstruction/PID details. Systematics defined this way will work on nuTree-derived spectra too (e.g. denominators of efficiencies).

Reimplemented in demo::DemoSyst1, ana::BeamSyst, ana::GenericSystComponentScale< T >, ana::GenericSystComponentScale< T >, ana::GenericSystComponentScale< T >, and ana::NOvARwgtSyst.

Definition at line 46 of file ISyst.h.

Referenced by ana::ISyst::Shift().

49  {
50  // Implement this function if your systematic depends only
51  // SRNeutrino. Left blank by default, since systematics using other
52  // information can do nothing sensible to the nuTree.
53  }

Member Data Documentation

const MECDoubleGaussEnhParamNux ana::MECDoubleGaussEnhSystNux::fShiftParam
private

Definition at line 297 of file MECSystsNux.h.

Referenced by Shift().


The documentation for this class was generated from the following file: