CMS 3D CMS Logo

Public Member Functions

ClopperPearsonBinomialInterval Class Reference

#include <ClopperPearsonBinomialInterval.h>

Inheritance diagram for ClopperPearsonBinomialInterval:
BinomialInterval TNamed

List of all members.

Public Member Functions

void calculate (const double successes, const double trials)
const char * name () const

Detailed Description

Definition at line 21 of file ClopperPearsonBinomialInterval.h.


Member Function Documentation

void ClopperPearsonBinomialInterval::calculate ( const double  successes,
const double  trials 
) [virtual]

Implements BinomialInterval.

Definition at line 16 of file ClopperPearsonBinomialInterval.cc.

References BinomialInterval::alpha_min_, BinomialInterval::lower_, and BinomialInterval::upper_.

                                                                             {
  set(0, 1);
  if (X > 0)
    lower_ = beta_quantile  (alpha_min_, X,     n - X + 1);
  if (n - X > 0)
    upper_ = beta_quantile_c(alpha_min_, X + 1, n - X);
}
const char* ClopperPearsonBinomialInterval::name ( void  ) const [inline, virtual]

Implements BinomialInterval.

Definition at line 24 of file ClopperPearsonBinomialInterval.h.

{ return "Clopper-Pearson"; }