yat  0.21pre
InputRanker.h
1 #ifndef _theplu_yat_classifier_inputranker_
2 #define _theplu_yat_classifier_inputranker_
3 
4 // $Id: InputRanker.h 4207 2022-08-26 04:36:28Z peter $
5 
6 /*
7  Copyright (C) 2004 Peter Johansson
8  Copyright (C) 2005, 2006, 2007, 2008 Jari Häkkinen, Peter Johansson
9  Copyright (C) 2013 Jari Häkkinen
10  Copyright (C) 2022 Peter Johansson
11 
12  This file is part of the yat library, http://dev.thep.lu.se/yat
13 
14  The yat library is free software; you can redistribute it and/or
15  modify it under the terms of the GNU General Public License as
16  published by the Free Software Foundation; either version 3 of the
17  License, or (at your option) any later version.
18 
19  The yat library is distributed in the hope that it will be useful,
20  but WITHOUT ANY WARRANTY; without even the implied warranty of
21  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
22  General Public License for more details.
23 
24  You should have received a copy of the GNU General Public License
25  along with yat. If not, see <http://www.gnu.org/licenses/>.
26 */
27 
28 #include <cstddef>
29 #include <vector>
30 
31 namespace theplu {
32 namespace yat {
33 namespace statistics {
34  class Score;
35 }
36 namespace classifier {
37 
38  class MatrixLookup;
39  class MatrixLookupWeighted;
40  class Target;
41 
47  {
48 
49  public:
55  InputRanker(const MatrixLookup&, const Target&, const statistics::Score&);
56 
63  const statistics::Score&);
64 
69  const std::vector<size_t>& id(void) const;
70 
75  const std::vector<size_t>& rank(void) const;
76 
85  double score(size_t rank) const;
86 
87  private:
88  std::vector<size_t> id_;
89  std::vector<size_t> rank_;
90  std::vector<double> score_;
91  };
92 
93 
94 }}} // of namespace classifier, yat, and theplu
95 
96 #endif
General view into utility::Matrix.
Definition: MatrixLookup.h:70
const std::vector< size_t > & rank(void) const
Class for containing sample labels.
Definition: Target.h:47
The Department of Theoretical Physics namespace as we define it.
General view into utility::MatrixWeighted.
Definition: MatrixLookupWeighted.h:63
InputRanker(const MatrixLookup &, const Target &, const statistics::Score &)
Interface Class for score classes.
Definition: Score.h:43
Class for ranking rows in a matrix, using a Score and a target vector.
Definition: InputRanker.h:46
double score(size_t rank) const
const std::vector< size_t > & id(void) const

Generated on Wed Jan 25 2023 03:34:29 for yat by  doxygen 1.8.14