ra4_stats
0341147a0dc35f80f4e12c6003afb76a38e2ed6e
|
#include <ios>
#include <string>
#include <vector>
#include <random>
#include "TH1D.h"
Go to the source code of this file.
Functions | |
std::string | GetParamString (int argc, char *argv[]) |
double | GetTestStatistic (double a, double b, double c, double d) |
std::vector< double > | SampleTestStatistic (std::mt19937 &prng, size_t n, double a, double b, double c, double d) |
double | QToP (double q) |
double | QToZ (double q) |
double | ZToQ (double z) |
double | ZToP (double z) |
double | PToQ (double p) |
double | PToZ (double p) |
std::vector< double > | GetSignificances (const std::vector< double > &b_qs, const std::vector< double > &sb_qs) |
std::vector< double > | GetSignificances (const std::vector< double > &sb_qs) |
double | FindFraction (const std::vector< double > &qs, double q) |
void | GetPredictions (double a_in, double b_in, double c_in, double d_in, double &a_out, double &b_out, double &c_out, double &d_out) |
double | BinLogLikelihood (double obs, double pred) |
void | PrintRates (std::ostream &out, const std::string &name, double a, double b, double c, double d) |
void | InitializePRNG (std::mt19937 &prng) |
void | PlotQDistributions (const std::string ¶ms, const std::vector< double > &b_qs, const std::vector< double > &sb_qs) |
void | PlotZDistributions (const std::string ¶ms, const std::vector< double > &b_qs, const std::vector< double > &sb_qs, double z=-1.) |
void | NormalizeWithOverflow (TH1D &h) |
double | AddInQuadrature (double x, double y) |
double | RealMax (const TH1D &h) |
double AddInQuadrature | ( | double | x, |
double | y | ||
) |
double BinLogLikelihood | ( | double | obs, |
double | pred | ||
) |
Definition at line 192 of file test_abcd.cxx.
References anonymous_namespace{test_abcd.cxx}::inf.
Referenced by GetTestStatistic().
double FindFraction | ( | const std::vector< double > & | qs, |
double | q | ||
) |
Definition at line 166 of file test_abcd.cxx.
References wilks_coverage::lower_bound().
Referenced by GetSignificances().
std::string GetParamString | ( | int | argc, |
char * | argv[] | ||
) |
Definition at line 92 of file test_abcd.cxx.
Referenced by main().
void GetPredictions | ( | double | a_in, |
double | b_in, | ||
double | c_in, | ||
double | d_in, | ||
double & | a_out, | ||
double & | b_out, | ||
double & | c_out, | ||
double & | d_out | ||
) |
Definition at line 183 of file test_abcd.cxx.
Referenced by GetTestStatistic(), and main().
std::vector<double> GetSignificances | ( | const std::vector< double > & | b_qs, |
const std::vector< double > & | sb_qs | ||
) |
Definition at line 150 of file test_abcd.cxx.
References FindFraction(), and PToZ().
Referenced by PlotZDistributions().
std::vector<double> GetSignificances | ( | const std::vector< double > & | sb_qs | ) |
Definition at line 158 of file test_abcd.cxx.
References QToZ().
double GetTestStatistic | ( | double | a, |
double | b, | ||
double | c, | ||
double | d | ||
) |
Definition at line 102 of file test_abcd.cxx.
References BinLogLikelihood(), and GetPredictions().
Referenced by main(), and SampleTestStatistic().
void InitializePRNG | ( | std::mt19937 & | prng | ) |
void NormalizeWithOverflow | ( | TH1D & | h | ) |
Definition at line 319 of file test_abcd.cxx.
Referenced by PlotQDistributions(), and PlotZDistributions().
void PlotQDistributions | ( | const std::string & | params, |
const std::vector< double > & | b_qs, | ||
const std::vector< double > & | sb_qs | ||
) |
Definition at line 216 of file test_abcd.cxx.
References plot_variations::c, anonymous_namespace{test_agnostic.cxx}::e, and NormalizeWithOverflow().
Referenced by main().
void PlotZDistributions | ( | const std::string & | params, |
const std::vector< double > & | b_qs, | ||
const std::vector< double > & | sb_qs, | ||
double | z = -1. |
||
) |
Definition at line 259 of file test_abcd.cxx.
References plot_variations::c, GetSignificances(), plot_variations::leg, NormalizeWithOverflow(), and QToZ().
Referenced by main().
void PrintRates | ( | std::ostream & | out, |
const std::string & | name, | ||
double | a, | ||
double | b, | ||
double | c, | ||
double | d | ||
) |
Definition at line 196 of file test_abcd.cxx.
Referenced by main().
double PToQ | ( | double | p | ) |
Definition at line 146 of file test_abcd.cxx.
double PToZ | ( | double | p | ) |
Definition at line 139 of file test_abcd.cxx.
References anonymous_namespace{test_abcd.cxx}::inf.
Referenced by GetSignificances(), and PToQ().
double QToP | ( | double | q | ) |
Definition at line 123 of file test_abcd.cxx.
double QToZ | ( | double | q | ) |
Definition at line 127 of file test_abcd.cxx.
Referenced by GetSignificances(), main(), and PlotZDistributions().
double RealMax | ( | const TH1D & | h | ) |
Definition at line 337 of file test_abcd.cxx.
std::vector<double> SampleTestStatistic | ( | std::mt19937 & | prng, |
size_t | n, | ||
double | a, | ||
double | b, | ||
double | c, | ||
double | d | ||
) |
double ZToP | ( | double | z | ) |
Definition at line 135 of file test_abcd.cxx.
double ZToQ | ( | double | z | ) |
Definition at line 131 of file test_abcd.cxx.
Referenced by PToQ().