[Rivet] Autobooking dataPointSet

Andy Buckley andy.buckley at durham.ac.uk
Wed Jan 28 17:37:18 GMT 2009


Frank Siegert wrote:
> Hi guys,
> 
> when I autobook a dataPointSet from the aida file, like:
> 
>   _myDPS = bookDataPointSet(18, 1, 1, "blabla");
> 
> where all xerrors = 0.0 (because it is a DPS, not a histogram) then it 
> returns me a DPS with a size (number of datapoints) of one less then the 
> size of the one in the aida file.
> 
> Has anybody noticed that before?

I doubt anyone has used it before! I just added that method for
completeness, but we haven't really had a use-case until now. I created
that routine by cutting and pasting what I had for histograms, and as
you'll see in Analysis.cc, I screwed up:

 IDataPointSet* Analysis::bookDataPointSet(const size_t datasetId,
                                           const size_t xAxisId,
                                           const size_t yAxisId,
                                           const string& title) {
    [...]
    for (size_t pt = 0; pt < edges.size()-1; ++pt) {

That "-1" probably shouldn't be there: it's a consequence of the fact
that there is one fewer bin than there are bin edges. Still the code is
wrong since there is no reason for the DPS x-errors to be symmetric. I'm
fixing this at the moment, but it will take a little longer to get it
working and committed: removing the "-1" as shown above *may* be
sufficient until then.

Thanks for finding and reporting ;)
Andy

-- 
Dr Andy Buckley
Institute for Particle Physics Phenomenology
Durham University
0191 3343798 | 0191 3732613 | www.insectnation.org


More information about the Rivet mailing list