1 | #ifndef _theplu_statistics_foldchange_ |
---|
2 | #define _theplu_statistics_foldchange_ |
---|
3 | |
---|
4 | // $Id: FoldChange.h 623 2006-09-05 02:13:12Z peter $ |
---|
5 | |
---|
6 | #include "Score.h" |
---|
7 | |
---|
8 | namespace theplu { |
---|
9 | |
---|
10 | class utility::vector; |
---|
11 | |
---|
12 | |
---|
13 | namespace statistics { |
---|
14 | |
---|
15 | /// |
---|
16 | /// @brief FoldChange |
---|
17 | /// |
---|
18 | /// This score is simply given by the difference by the group means. |
---|
19 | /// |
---|
20 | class FoldChange : public Score |
---|
21 | { |
---|
22 | public: |
---|
23 | |
---|
24 | /// |
---|
25 | /// @brief Default Constructor |
---|
26 | /// |
---|
27 | FoldChange(bool absolute=true); |
---|
28 | |
---|
29 | /// |
---|
30 | /// @return difference of the means of the two classes |
---|
31 | /// |
---|
32 | /// @param target |
---|
33 | /// @param value vector of the values |
---|
34 | /// |
---|
35 | double score(const classifier::Target& target, |
---|
36 | const utility::vector& value); |
---|
37 | |
---|
38 | /// |
---|
39 | /// @return difference of the means of the two classes |
---|
40 | /// |
---|
41 | /// @param target |
---|
42 | /// @param value vector of the values (with weights) |
---|
43 | /// |
---|
44 | double score(const classifier::Target& target, |
---|
45 | const classifier::DataLookupWeighted1D& value); |
---|
46 | |
---|
47 | /// |
---|
48 | /// @return difference of the weighted means of the two classes |
---|
49 | /// |
---|
50 | /// @param target |
---|
51 | /// @param value vector of the values |
---|
52 | /// @param weight vector of accompanied weight to the values |
---|
53 | /// @train_set defining which values to use (number of values used |
---|
54 | /// in the calculation is equal to size of \a train_set) |
---|
55 | /// |
---|
56 | double score(const classifier::Target& target, |
---|
57 | const utility::vector& value, |
---|
58 | const utility::vector& weight); |
---|
59 | |
---|
60 | private: |
---|
61 | |
---|
62 | /// |
---|
63 | /// @brief Copy Constructor |
---|
64 | /// |
---|
65 | FoldChange(const FoldChange&); |
---|
66 | |
---|
67 | /// |
---|
68 | /// @brief Assignment operator |
---|
69 | /// |
---|
70 | FoldChange& operator=(const FoldChange&); |
---|
71 | |
---|
72 | }; |
---|
73 | |
---|
74 | } // of namespace statistics |
---|
75 | } // of namespace theplu |
---|
76 | |
---|
77 | #endif |
---|