npstat is hosted by Hepforge, IPPP Durham
NPStat  5.10.0
ProductSymmetricBetaNDCdf.hh
Go to the documentation of this file.
1 #ifndef NPSTAT_PRODUCTSYMMETRICBETANDCDF_HH_
2 #define NPSTAT_PRODUCTSYMMETRICBETANDCDF_HH_
3 
4 /*!
5 // \file ProductSymmetricBetaNDCdf.hh
6 //
7 // \brief Multivariate cumulative distribution for product
8 // symmetric beta density
9 //
10 // Author: I. Volobouev
11 //
12 // July 2012
13 */
14 
15 #include <vector>
16 
19 
20 namespace npstat {
21  /**
22  // Multivariate cumulative distribution for product symmetric
23  // beta density. Can be used as the weight functor with the
24  // npstat::mergeTwoHistos function.
25  */
27  {
28  public:
29  /**
30  // The constructor takes array arguments. Each array element is
31  // used for one of the dimensions. "dim" gives the size of all
32  // arrays as well as the function dimensionality.
33  //
34  // location -- mean of SymmetricBeta1D in each dimension
35  //
36  // scale -- scale parameter of SymmetricBeta1D in each dimension
37  //
38  // power -- power parameter of SymmetricBeta1D in each dimension
39  //
40  // direction -- a flag which tells us what to do with the cumulative
41  // distribution of SymmetricBeta1D. Meanings are as
42  // follows:
43  // >0 -- use exceedance (1 - cdf, weight decreasing)
44  // 0 -- do not use this dimension at all (factor of 1
45  // will be used everywhere instead of cdf)
46  // <0 -- use cdf (weight increasing)
47  */
48  ProductSymmetricBetaNDCdf(const double* location, const double* scale,
49  const double* power, const int* direction,
50  unsigned dim);
51 
52  inline virtual ~ProductSymmetricBetaNDCdf() {}
53 
54  virtual double operator()(const double* point, unsigned dim) const;
55 
56  inline virtual unsigned minDim() const {return dim_;}
57 
58  private:
59  std::vector<SymmetricBeta1D> marginals_;
60  std::vector<int> directions_;
61  unsigned dim_;
62  };
63 }
64 
65 #endif // NPSTAT_PRODUCTSYMMETRICBETANDCDF_HH_
Interface definition for multidimensional functors.
A number of useful 1-d continuous statistical distributions.
Definition: ProductSymmetricBetaNDCdf.hh:27
ProductSymmetricBetaNDCdf(const double *location, const double *scale, const double *power, const int *direction, unsigned dim)
virtual double operator()(const double *point, unsigned dim) const
virtual unsigned minDim() const
Definition: ProductSymmetricBetaNDCdf.hh:56
Definition: AbsArrayProjector.hh:14
Definition: AbsMultivariateFunctor.hh:19