TH1(const char* name, const char* title, Int_t nbinsx, const Float_t* xbins)
TH1(const char* name, const char* title, Int_t nbinsx, const Double_t* xbins)
e.g.
double xbins[4] = {0,0.25,0.5,1.0};
TH1F("example", "example", 3, xbins);
off you go.
On Mon, 12 Dec 2005, Peter Karpius wrote:
> Does anyone know how to make a histogram with multiple bin widths in Root?
>
> 	That is, I have a histogram with 2 bins with a range of 0 to 1 for 
> example.  The first bin goes from 0 to 0.5 and the second from 0.5 to 1.0.
> Now, I want to have three bins where I split the 1st bin in half so that I 
> have:
>
> Bin 1:  0 - 0.25
> Bin 2:	0.25 - 0.5
> Bin 3:  0.5 - 1.0
>
> 		Other than generating multiple histograms (my specialty is 
> violating Occam's Razor!), how do I do this?
>
> 	I have checked the Root web page for this but to no avail.
>
> 					Thanks,
> 					Pete
> ----------------------------------------------
> Pete Karpius
> Graduate Research Assistant
> Nuclear Physics Group
> University of New Hampshire
> phone: (603)978-6152
> FAX:   (603)862-2998
> email: karpiusp@einstein.unh.edu
> http://pubpages.unh.edu/~pkarpius/homepage.htm
> ----------------------------------------------
>
This archive was generated by hypermail 2.1.2 : Mon Feb 24 2014 - 14:07:32 EST