23 bool showGraphics =
false;
41 vector<Double_t>
x( ARRAYSIZE );
42 vector<Double_t> yb( ARRAYSIZE );
43 vector<Double_t> ymb( ARRAYSIZE );
47 double b = 0.2,
a= 0.9;
48 cout <<
"** b = " << b <<
" **" << endl;
49 unsigned int index = 0;
53 cout <<
"i:"; cout.width(5); cout << i
54 <<
" index: "; cout.width(5); cout << index
64 if (
std::fabs( yb[index] - ymb[index] ) > ERRORLIMIT )
67 <<
" yb[index] " << yb[index]
68 <<
" ymb[index] " << ymb[index]
69 <<
" " <<
std::fabs( yb[index] - ymb[index] )
80 TH2F* hpx =
new TH2F(
"hpx",
"Two Graphs(hpx)", ARRAYSIZE, MIN, MAX, ARRAYSIZE, 0, 5);
91 legend->
AddEntry(gb,
"TMath::BetaIncomplete()");
92 legend->
AddEntry(gmb,
"ROOT::Math::inc_beta()");
98 cout <<
"Test Done!" << endl;
103 int main(
int argc,
char **argv)
106 for (
Int_t i=1 ; i<argc ; i++) {
107 std::string arg = argv[i] ;
116 cerr <<
"Usage: " << argv[0] <<
" [-g] [-v]\n";
118 cerr <<
" -g : graphics mode\n";
119 cerr <<
" -v : verbose mode";
virtual void SetLineWidth(Width_t lwidth)
This class displays a legend box (TPaveText) containing several legend entries.
int main(int argc, char **argv)
virtual void Draw(Option_t *option="")
Draw this legend with its current attributes.
double inc_beta(double x, double a, double b)
Calculates the normalized (regularized) incomplete beta function.
virtual void Draw(Option_t *chopt="")
Draw this graph with its current attributes.
virtual void Run(Bool_t retrn=kFALSE)
Main application eventloop. Calls system dependent eventloop via gSystem.
virtual void SetLineColor(Color_t lcolor)
VecExpr< UnaryOp< Fabs< T >, VecExpr< A, T, D >, T >, T, D > fabs(const VecExpr< A, T, D > &rhs)
virtual void Draw(Option_t *option="")
Draw this histogram with options.
2-D histogram with a float per channel (see TH1 documentation)}
TLegendEntry * AddEntry(const TObject *obj, const char *label="", Option_t *option="lpf")
Add a new entry to this legend.
TGraph * drawPoints(Double_t x[], Double_t y[], int color, int style=1)
virtual void SetLineStyle(Style_t lstyle)
A Graph is a graphics object made of two arrays X and Y with npoints each.
This class creates the ROOT Application Environment that interfaces to the windowing system eventloop...
Double_t BetaIncomplete(Double_t x, Double_t a, Double_t b)
Calculates the incomplete Beta-function.
virtual void SetStats(Bool_t stats=kTRUE)
Set statistics option on/off.