Changeset 671


Ignore:
Timestamp:
Oct 7, 2006, 8:25:22 AM (15 years ago)
Author:
Peter
Message:

fixed some percentile dox refs #69

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/c++_tools/statistics/utility.h

    r648 r671  
    7575  double median(const utility::vector& vec, const bool sorted=false);
    7676
    77   ///
    78   /// The percentile is determined by the \a p, a number between 0 and
    79   /// 100. The percentile is found by interpolation, using the formula
    80   /// \f$ percentile = (1 - \delta) x_i + \delta x_{i+1} \f$ where \a
    81   /// p is floor\f$((n - 1)p/100)\f$ and \f$ \delta \f$ is \f$
    82   /// (n-1)p/100 - i \f$.Thus the minimum value of the vector is given
    83   /// by p equal to zero, the maximum is given by p equal to 100 and
    84   /// the median value is given by p equal to 50. If @a sorted
    85   /// is false (default), the vector is copied, the copy is sorted,
    86   /// and then used to calculate the median.
    87   ///
    88   /// @return \a p'th percentile
    89   ///
     77  /**
     78    The percentile is determined by the \a p, a number between 0 and
     79    100. The percentile is found by interpolation, using the formula
     80    \f$ percentile = (1 - \delta) x_i + \delta x_{i+1} \f$ where \a
     81    p is floor\f$((n - 1)p/100)\f$ and \f$ \delta \f$ is \f$
     82    (n-1)p/100 - i \f$.Thus the minimum value of the vector is given
     83    by p equal to zero, the maximum is given by p equal to 100 and
     84    the median value is given by p equal to 50. If @a sorted
     85    is false (default), the vector is copied, the copy is sorted,
     86    and then used to calculate the median.
     87   
     88    @return \a p'th percentile
     89  */
    9090  template <class T>
    9191  double percentile(const std::vector<T>& vec, const double p,
     
    110110  }
    111111
    112   ///
    113   /// The percentile is determined by the \a p, a number between 0 and
    114   /// 100. The percentile is found by interpolation, using the formula
    115   /// \f$ percentile = (1 - \delta) x_i + \delta x_{i+1} \f$ where \a
    116   /// p is floor\f$((n - 1)p/100)\f$ and \f$ \delta \f$ is \f$
    117   /// (n-1)p/100 - i \f$.Thus the minimum value of the vector is given
    118   /// by p equal to zero, the maximum is given by p equal to 100 and
    119   /// the median value is given by p equal to 50. If @a sorted
    120   /// is false (default), the vector is copied, the copy is sorted,
    121   /// and then used to calculate the median.
    122   ///
    123   /// @return \a p'th percentile
    124   ///
     112  /**
     113    The percentile is determined by the \a p, a number between 0 and
     114    100. The percentile is found by interpolation, using the formula
     115    \f$ percentile = (1 - \delta) x_i + \delta x_{i+1} \f$ where \a
     116    p is floor\f$((n - 1)p/100)\f$ and \f$ \delta \f$ is \f$
     117    (n-1)p/100 - i \f$.Thus the minimum value of the vector is given
     118    by p equal to zero, the maximum is given by p equal to 100 and
     119    the median value is given by p equal to 50. If @a sorted
     120    is false (default), the vector is copied, the copy is sorted,
     121    and then used to calculate the median.
     122   
     123    @return \a p'th percentile
     124  */
    125125  double percentile(const utility::vector& vec, const double,
    126126                    const bool sorted=false);
Note: See TracChangeset for help on using the changeset viewer.