Ignore:
Timestamp:
May 12, 2008, 10:35:10 AM (13 years ago)
Author:
Jari Häkkinen
Message:

Fixes #361. Averager and AveragerPair? accepts negative n for data removal.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/yat/statistics/Averager.h

    r1275 r1295  
    77  Copyright (C) 2004 Jari Häkkinen, Peter Johansson
    88  Copyright (C) 2005, 2006 Jari Häkkinen, Peter Johansson, Markus Ringnér
    9   Copyright (C) 2007 Jari Häkkinen, Peter Johansson
    10   Copyright (C) 2008 Peter Johansson
     9  Copyright (C) 2007, 2008 Jari Häkkinen, Peter Johansson
    1110
    1211  This file is part of the yat library, http://trac.thep.lu.se/yat
     
    5655    /// number of samples \a n.
    5756    ///
    58     Averager(double x, double xx, unsigned long n);
     57    Averager(double x, double xx, long n);
    5958
    6059    ///
     
    6665    /// Adding \a n (default=1) number of data point(s) with value \a d.
    6766    ///
    68     void add(double d, unsigned long n=1);
     67    void add(double d, long n=1);
    6968
    7069    /**
     
    8685    /// @return Number of data points
    8786    ///
    88     unsigned long n(void) const;
     87    long n(void) const;
    8988
    9089    ///
     
    179178
    180179  private:
    181     unsigned long n_;
     180    long  n_;
    182181    double  x_, xx_;
    183182  };
Note: See TracChangeset for help on using the changeset viewer.