Represent the ratio between two spectra. More...
#include "/cvmfs/nova.opensciencegrid.org/externals/cafanacore/v01.15/src/CAFAna/Core/Ratio.h"
Public Member Functions | |
Ratio (const Spectrum &num, const Spectrum &denom, bool purOrEffErrs=false) | |
Ratio (Eigen::ArrayXd &&arr, const std::vector< std::string > &labels, const std::vector< Binning > &bins) | |
virtual | ~Ratio () |
Ratio (const Ratio &rhs)=default | |
Ratio & | operator= (const Ratio &rhs)=default |
Ratio & | operator*= (const Ratio &rhs) |
Ratio | operator* (const Ratio &rhs) const |
Ratio & | operator/= (const Ratio &rhs) |
Ratio | operator/ (const Ratio &rhs) const |
TH1D * | ToTH1 (Color_t col=kBlack, Style_t style=kSolid) const |
TH2 * | ToTH2 () const |
bool | HasStan () const |
const Eigen::ArrayXd & | GetEigen () const |
const Eigen::ArrayXstan & | GetEigenStan () const |
Protected Member Functions | |
Ratio (Hist &&h, std::vector< Binning > &&b, std::vector< std::string > &&l) | |
Protected Attributes | |
Hist | fHist |
LabelsAndBins | fAxis |
Friends | |
class | Spectrum |
num | Numerator of the ratio |
denom | Denominator of the ratio |
purOrEffErrs | Does this ratio represent a purity or efficiency plot? If so, error bars are calculated differently. |
Definition at line 11 of file Ratio.cxx.
References ana::Hist::Divide(), fHist, ana::Spectrum::fHist, ana::Hist::GetBinContent(), ana::Hist::GetNbinsX(), MECModelEnuComparisons::i, ana::Spectrum::POT(), ana::Hist::Scale(), and ana::Hist::SetBinContent().
Referenced by ana::operator/(), and Ratio().
|
inline |
Definition at line 20 of file Ratio.h.
References col, operator*(), operator*=(), operator/(), operator/=(), operator=(), Ratio(), ToTH1(), ToTH2(), and ~Ratio().
|
virtual |
|
default |
|
inlineprotected |
|
inline |
Definition at line 44 of file Ratio.h.
References fHist, and ana::Hist::GetEigen().
Referenced by ana::PredictionExtendToPeripheral::ExtendRecoWeight(), ana::PredictionExtendToPeripheral::ExtendRecoWeightOscillatable(), ana::ReweightableSpectrum::ReweightToRecoSpectrum(), ana::ReweightableSpectrum::ReweightToTrueSpectrum(), and ana::ReweightableSpectrum::WeightedBy().
|
inline |
Definition at line 45 of file Ratio.h.
References fHist, and ana::Hist::GetEigenStan().
Referenced by ana::ReweightableSpectrum::WeightedBy().
|
inline |
Definition at line 43 of file Ratio.h.
References fHist, and ana::Hist::HasStan().
Referenced by ana::ReweightableSpectrum::WeightedBy().
Definition at line 44 of file Ratio.cxx.
References runNovaSAM::ret.
Referenced by Ratio().
Definition at line 37 of file Ratio.cxx.
References fHist, and ana::Hist::Multiply().
Referenced by Ratio().
Definition at line 59 of file Ratio.cxx.
References runNovaSAM::ret.
Referenced by Ratio().
Definition at line 52 of file Ratio.cxx.
References ana::Hist::Divide(), and fHist.
Referenced by Ratio().
TH1D * ana::Ratio::ToTH1 | ( | Color_t | col = kBlack , |
Style_t | style = kSolid |
||
) | const |
Definition at line 67 of file Ratio.cxx.
References fAxis, fHist, ana::LabelsAndBins::GetBins1D(), ana::LabelsAndBins::GetLabel1D(), runNovaSAM::ret, and ana::Hist::ToTH1().
Referenced by ana::DataMCRatio(), demo::DrawUpDownRatioCanvas(), ana::MichelDecomp::GetNCMCContent(), ana::MichelDecomp::GetNCScale(), ana::MichelDecomp::GetNueScale(), ana::MichelDecomp::GetNumuMCContent(), ana::MichelDecomp::GetNumuScale(), make_xs(), make_xs_1D(), ana::CrossSectionAnalysis::PlotEfficiency(), ana::NumuCCIncAnalysis::PlotEfficiency(), Plotting_Data2DataComp(), Plotting_Data2DataComp_SingleCanvas(), Plotting_DataAndPrediction(), PredRatioToNom(), Ratio(), ana::RatioPlot(), test_nuwro(), ana::NDOscCurve::ToTH1(), ana::OscCurve::ToTH1(), ToTH2(), ana::ToTH2(), ana::ToTH3(), Unfold1D(), and Unfold3D().
TH2 * ana::Ratio::ToTH2 | ( | ) | const |
Definition at line 78 of file Ratio.cxx.
References om::cout, allTimeWatchdog::endl, fAxis, ana::LabelsAndBins::GetBinnings(), ana::LabelsAndBins::GetLabels(), ana::LabelsAndBins::NDimensions(), runNovaSAM::ret, ToTH1(), and ana::ToTH2Helper().
Referenced by ana::SingleNucAnalysis::PlotEfficiency2D(), ana::NumuCC2p2hAnalysis::PlotEfficiency2D(), and Ratio().
|
protected |
|
protected |
Definition at line 56 of file Ratio.h.
Referenced by GetEigen(), GetEigenStan(), HasStan(), operator*=(), ana::Spectrum::operator*=(), operator/=(), ana::Spectrum::operator/=(), Ratio(), and ToTH1().