source: trunk/yat/statistics/FoldChange.h @ 1000

Last change on this file since 1000 was 1000, checked in by Jari Häkkinen, 15 years ago

trac moved to new location.

  • Property svn:eol-style set to native
  • Property svn:keywords set to Id
File size: 2.3 KB
Line 
1#ifndef _theplu_yat_statistics_foldchange_
2#define _theplu_yat_statistics_foldchange_
3
4// $Id: FoldChange.h 1000 2007-12-23 20:09:15Z jari $
5
6/*
7  Copyright (C) 2005 Peter Johansson
8  Copyright (C) 2006 Jari Häkkinen, Peter Johansson
9  Copyright (C) 2007 Peter Johansson
10
11  This file is part of the yat library, http://trac.thep.lu.se/yat
12
13  The yat library is free software; you can redistribute it and/or
14  modify it under the terms of the GNU General Public License as
15  published by the Free Software Foundation; either version 2 of the
16  License, or (at your option) any later version.
17
18  The yat library is distributed in the hope that it will be useful,
19  but WITHOUT ANY WARRANTY; without even the implied warranty of
20  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
21  General Public License for more details.
22
23  You should have received a copy of the GNU General Public License
24  along with this program; if not, write to the Free Software
25  Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
26  02111-1307, USA.
27*/
28
29#include "Score.h"
30
31namespace theplu {
32namespace yat {
33
34  class utility::vector;
35
36namespace statistics {
37
38  ///
39  /// @brief Score given by the difference by the group means.
40  ///
41  class FoldChange : public Score
42  {
43  public:
44
45    ///
46    /// @brief Default Constructor
47    ///
48    FoldChange(bool absolute=true);
49
50    ///
51    /// @return difference of the means of the two classes
52    ///
53    /// @param target
54    /// @param value vector of the values
55    ///
56    double score(const classifier::Target& target, 
57                 const utility::vector& value) const; 
58 
59    ///
60    /// @return difference of the means of the two classes
61    ///
62    /// @param target
63    /// @param value vector of the values (with weights)
64    ///
65    double score(const classifier::Target& target, 
66                 const classifier::DataLookupWeighted1D& value) const; 
67 
68    ///
69    /// @return difference of the weighted means of the two classes
70    ///
71    /// @param target
72    /// @param value vector of the values
73    /// @param weight vector of accompanied weight to the values
74    ///
75    double score(const classifier::Target& target, 
76                 const utility::vector& value,
77                 const utility::vector& weight) const; 
78 
79  private:
80
81    ///
82    /// @brief Copy Constructor
83    ///
84    FoldChange(const FoldChange&);
85
86    ///
87    /// @brief Assignment operator
88    ///
89    FoldChange& operator=(const FoldChange&);
90
91  };
92
93}}} // of namespace statistics, yat, and theplu
94
95#endif
Note: See TracBrowser for help on using the repository browser.