gibuu is hosted by Hepforge, IPPP Durham
GiBUU

Changes between Version 1 and Version 2 of HowToHistogram


Ignore:
Timestamp:
Apr 29, 2009, 9:06:48 PM (15 years ago)
Author:
gallmei
Comment:

correcting some typos + minor rephrasing.

Legend:

Unmodified
Added
Removed
Modified
  • HowToHistogram

    v1 v2  
    1818   call AddHist(H, x,y)
    1919   }}}
    20    This adds in histogram "'''H'''" to the bin, where "'''x'''" corresponds to, the value "'''y'''".[[BR]][[BR]]
     20   This adds in histogram "'''H'''" the value "'''y'''" to the bin where "'''x'''" corresponds to.[[BR]][[BR]]
    2121   Alternatevily you can use
    2222   {{{
    2323   call AddHist(H, x,y, y2)
    2424   }}}
    25    where you are internally filling two histograms at the same time. (Why the hell you ever would do something like this: see below!)
     25   where you are internally filling two histograms at the same time. (Why the hell you ever would like to do such: see below!)
    2626
    2727 * At the end, you write out the histogram by
     
    3131   Here "'''H'''" and "'''iFile'''" are the only obligatory parameters (the histogram and the number of the file to write it), the other parameters are optional. (It has shown up to be a good idea to give optional arguments always in the form "''optarg=optarg_value''", since you then do not have to take care of the correct ordering.)[[BR]][[BR]]
    3232   The sum of all entries per bin are automatically divided by the bin width, in order to get the correct scaling. In addition, you may specify "'''add'''" and/or "'''mul'''" to get some additional scaling: instead of "Y", the printed output is "'add'+Y*'mul'". [I like to call it with "add=1e-20" when creating log-plots in order to avoid problems while ploting "0" in a log-plot (KG)][[BR]][[BR]]
    33    The parameter "'''!DoAve'''" is 'logical' and indicates, whether we want to print also "per bin averages": If this feature is selected, then also on a per-bin-basis we write the value of "sum(y2-entries)/sum(y-entries)", which can the be interpreted as "<y2>(x)", while the normal output is "dN/dx" and "dN2/dx". (Argument "'''maxval'''" is the value, which is printed, if the bin is empty.)[[BR]][[BR]]
    34    You can give a second histogram via parameter "'''H2'''", the all output is divided bin-by-bin by the entries of this second histogramm.[[BR]][[BR]]
     33   The parameter "'''!DoAve'''" is 'logical' and indicates, whether we want to print also "per bin averages": If this feature is selected, then also on a per-bin-basis we write the value of "sum(y2-entries)/sum(y-entries)", which can be interpreted as "<y2>(x)", while the normal output is "dN/dx" and "dN2/dx". (Argument "'''maxval'''" is the value, which is printed, if there are no entries in a specific bin.)[[BR]][[BR]]
     34   You can give a second histogram via parameter "'''H2'''", then all output is divided bin-by-bin by the entries of this second histogrmm.[[BR]][[BR]]
    3535   If you give a string as argument for "'''file'''", the the output routines opens the file with the given name "file" for output as stream "iFile", does the output and closes stream "iFile" afterwards again.[[BR]][[BR]]
    3636   The last optional (logical) parameter "'''dump'''" indicates, whether you want in addition to the ASCII output also some binary dump of all the information stored. This may be helpful, if you want to read in the information again by some additional Fortran program to further manipulate the output, e.g. increasing the statistics by averaging over 10 runs with different random seeds.[[BR]][[BR]]