11 void candleplotstack()
23 for (
int i = dateBegin->
Convert(); i < dateEnd->
Convert(); i+=86400*30) {
24 for (
int j = 0; j < 1000; j++) {
25 Rand = randnum->
Gaus(500+
sin(i/10000000.)*100,50); h1->
Fill(i,Rand); hsum->Fill(i,Rand);
26 Rand = randnum->
Gaus(500+
sin(i/12000000.)*100,50); h2->Fill(i,Rand); hsum->Fill(i,Rand);
30 h2->SetLineColor(
kRed);
31 hsum->SetFillColor(
kGreen);
36 hs->
Add(h2,
"candle2");
37 hs->
Add(hsum,
"violin1");
49 gPad->BuildLegend(0.75,0.75,0.95,0.95,
"");
The Histogram stack class.
virtual void SetTimeFormat(const char *format="")
Change the format used for time plotting.
virtual Double_t Gaus(Double_t mean=0, Double_t sigma=1)
Samples a random number from the standard Normal (Gaussian) Distribution with the given mean and sigm...
R__EXTERN TStyle * gStyle
TAxis * GetXaxis() const
Get x axis of the histogram used to draw the stack.
virtual void SetNdivisions(Int_t n=510, Bool_t optim=kTRUE)
Set the number of divisions for this axis.
void SetTimeOffset(Double_t toffset)
Change the time offset for time plotting.
virtual void Draw(Option_t *chopt="")
Draw this multihist with its current attributes.
This is the base class for the ROOT Random number generators.
virtual void SetTimeDisplay(Int_t value)
virtual void Add(TH1 *h, Option_t *option="")
add a new histogram to the list Only 1-d and 2-d histograms currently supported.
UInt_t Convert(Bool_t toGMT=kFALSE) const
Convert fDatime from TDatime format to the standard time_t format.
THist< 2, int, THistStatContent > TH2I
2-D histogram with an int per channel (see TH1 documentation)}
Int_t Fill(Double_t)
Invalid Fill method.
virtual void SetTitle(const char *title="")
Set the title of the TNamed.
void Modified(Bool_t flag=1)
This class stores the date and time with a precision of one second in an unsigned 32 bit word (950130...