Ignore:
Timestamp:
Dec 26, 2006, 10:56:26 AM (15 years ago)
Author:
Jari Häkkinen
Message:

Addresses #170.

File:
1 edited

Legend:

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

    r703 r718  
    5959    virtual ~ROC(void);
    6060         
     61    ///
     62    /// minimum_size is the threshold for when a normal
     63    /// approximation is used for the p-value calculation.
     64    ///
     65    /// @return reference to minimum_size
     66    ///
     67    u_int& minimum_size(void);
     68
     69    ///
     70    /// @return number of samples
     71    ///
     72    size_t n(void) const;
     73
     74    ///
     75    /// @return number of positive samples (Target.binary()==true)
     76    ///
     77    size_t n_pos(void) const;
     78
     79    ///
     80    ///Calculates the p-value, i.e. the probability of observing an
     81    ///area equally or larger if the null hypothesis is true. If P is
     82    ///near zero, this casts doubt on this hypothesis. The null
     83    ///hypothesis is that the values from the 2 classes are generated
     84    ///from 2 identical distributions. The alternative is that the
     85    ///median of the first distribution is shifted from the median of
     86    ///the second distribution by a non-zero amount. If the smallest
     87    ///group size is larger than minimum_size (default = 10), then P
     88    ///is calculated using a normal approximation.  @return the
     89    ///one-sided p-value( if absolute true is used this is equivalent
     90    ///to the two-sided p-value.)
     91    ///
     92    double p_value(void) const;
     93   
    6194    /// Function taking \a value, \a target (+1 or -1) and vector
    6295    /// defining what samples to use. The score is equivalent to
     
    83116    double score(const classifier::Target& target,
    84117                 const classifier::DataLookupWeighted1D& value);
    85        
    86118
    87119    /**
     
    100132                 const utility::vector& value,
    101133                 const utility::vector& weight);
    102        
    103 
    104     ///
    105     ///Calculates the p-value, i.e. the probability of observing an
    106     ///area equally or larger if the null hypothesis is true. If P is
    107     ///near zero, this casts doubt on this hypothesis. The null
    108     ///hypothesis is that the values from the 2 classes are generated
    109     ///from 2 identical distributions. The alternative is that the
    110     ///median of the first distribution is shifted from the median of
    111     ///the second distribution by a non-zero amount. If the smallest
    112     ///group size is larger than minimum_size (default = 10), then P
    113     ///is calculated using a normal approximation.  @return the
    114     ///one-sided p-value( if absolute true is used this is equivalent
    115     ///to the two-sided p-value.)
    116     ///
    117     double p_value(void) const;
    118    
    119     ///
    120     /// minimum_size is the threshold for when a normal
    121     /// approximation is used for the p-value calculation.
    122     ///
    123     /// @return reference to minimum_size
    124     ///
    125     inline u_int& minimum_size(void){ return minimum_size_; } 
    126134
    127135    ///
     
    132140    ///
    133141    bool target(const size_t i) const;
    134 
    135     ///
    136     /// @return number of samples
    137     ///
    138     inline size_t n(void) const { return vec_pair_.size(); }
    139 
    140     ///
    141     /// @return number of positive samples (Target.binary()==true)
    142     ///
    143     inline size_t n_pos(void) const { return nof_pos_; }
    144142
    145143  private:
Note: See TracChangeset for help on using the changeset viewer.