47 PredictionConcat*
sim = GetDefaultSimulation();
54 CovarianceMatrix* mx = GetFullCovMx(sim, calc, fd_pot);
57 TCanvas*
c =
new TCanvas();
62 TFile* plotfile =
new TFile(Form(
"plots/covmx/%sPlots.root",polarity.c_str()),
"recreate");
68 TH2D* h_full = mx->GetFullCovMxTH2();
71 c->Write(Form(
"CovMx%sFull",polarity.c_str()));
72 c->SaveAs(Form(
"plots/covmx/CovMx%sFull.png",polarity.c_str()));
73 c->SaveAs(Form(
"plots/covmx/CovMx%sFull.pdf",polarity.c_str()));
80 std::vector<double>
bin_edges = sim->GetBinEdges();
82 TH2D* h_osc_abs = mx->GetCovMxAbsoluteTH2();
83 h_osc_abs->Draw(
"colz");
84 c->Write(Form(
"CovMx%sOscAbs",polarity.c_str()));
85 c->SaveAs(Form(
"plots/covmx/CovMx%sOscAbs.png",polarity.c_str()));
86 c->SaveAs(Form(
"plots/covmx/CovMx%sOscAbs.pdf",polarity.c_str()));
93 auto nominal = sim->Predict(calc).ToTH1(fd_pot);
94 int nbins = nominal->GetNbinsX();
97 v_pred(
i) = nominal->GetBinContent(
i+1);
98 TH2D* h_osc_rel = mx->GetCovMxRelativeTH2(v_pred);
99 h_osc_rel->Draw(
"colz");
100 h_osc_rel->GetYaxis()->SetTitle(
"");
101 h_osc_rel->GetXaxis()->SetTitle(
"Deposited energy bins");
102 h_osc_rel->GetXaxis()->CenterTitle();
108 TLine lx(0, max_e, 2 * max_e, max_e);
110 TLine ly(max_e, 0, max_e, 2 * max_e);
116 c->Write(Form(
"CovMx%sRelative",polarity.c_str()));
117 c->SaveAs(Form(
"plots/covmx/CovMx%sOscRel.png",polarity.c_str()));
118 c->SaveAs(Form(
"plots/covmx/CovMx%sOscRel.pdf",polarity.c_str()));
Cuts and Vars for the 2020 FD DiF Study.
std::vector< std::tuple< ana::Flavors::Flavors_t, ana::Current::Current_t, ana::Sign::Sign_t > > GetComponents()
void FormatFullCovMxPlot(TH2D *h, PredictionConcat *sim)
void DrawCovMx(bool rhc=false)
Adapt the PMNS_Sterile calculator to standard interface.
TLatex * MiscText(float x, float y, float size, TString text)
const double kAna2018SensitivityFHCNDPOT
void FormatCanvas()
Canvas formatting utility.
void SetAngles(osc::OscCalcSterile *calc)
const double kAna2018RHCPOT
osc::OscCalcSterile * DefaultSterileCalc(int nflavors)
Create a sterile calculator with default assumptions for all parameters.
Example routine for calculating the "ultimate e-m mother" of a particle in a simulated event...
const double kAna2018SensitivityRHCNDPOT
const double kAna2018FHCPOT
Prevent histograms being added to the current directory.
const double kAna2018FHCLivetime
const double kAna2018RHCLivetime