CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
JacknifeQuantile.h
Go to the documentation of this file.
1 #include <vector>
2 #include <algorithm>
3 struct RooAbsData;
4 
6  public:
8 
11  QuantileCalculator(const std::vector<double> &values, const std::vector<double> &weights = std::vector<double>());
12  QuantileCalculator(const std::vector<float> &values, const std::vector<float> &weights = std::vector<float>());
13  QuantileCalculator(const RooAbsData &data, const char *varName, int firstEntry=0, int lastEntry=-1);
15  void randomizePoints() ;
16  std::pair<double,double> quantileAndError(double quantile, Method method);
17  private:
18  struct point {
19  float x, w;
20  int set;
21  inline bool operator<(const point &other) const { return x < other.x; }
22  };
23  std::vector<point> points_;
24  std::vector<double> sumw_;
25  std::vector<float> quantiles_;
26 
27  int guessPartitions(int size, double quantile) ;
28  template<typename T> void import(const std::vector<T> &values, const std::vector<T> &weights) ;
29  void partition(int m, bool doJacknife) ;
30  void quantiles(double quantile, bool doJacknife);
31 
32 };
33 
std::vector< float > quantiles_
void partition(int m, bool doJacknife)
std::pair< double, double > quantileAndError(double quantile, Method method)
std::vector< double > sumw_
void quantiles(double quantile, bool doJacknife)
std::vector< point > points_
bool operator<(const point &other) const
char data[epos_bytes_allocation]
Definition: EPOS_Wrapper.h:82
void randomizePoints()
Randomize points before sectioning.
tuple size
Write out results.
int guessPartitions(int size, double quantile)