SHOGUN
v2.0.0
Main Page
Related Pages
Modules
Classes
Files
File List
File Members
All
Classes
Namespaces
Files
Functions
Variables
Typedefs
Enumerations
Enumerator
Friends
Macros
Groups
Pages
src
shogun
statistics
TestStatistic.h
Go to the documentation of this file.
1
/*
2
* This program is free software; you can redistribute it and/or modify
3
* it under the terms of the GNU General Public License as published by
4
* the Free Software Foundation; either version 3 of the License, or
5
* (at your option) any later version.
6
*
7
* Written (W) 2012 Heiko Strathmann
8
*/
9
10
#ifndef __TESTSTATISTIC_H_
11
#define __TESTSTATISTIC_H_
12
13
#include <
shogun/base/SGObject.h
>
14
15
namespace
shogun
16
{
17
19
enum
ENullApproximationMethod
20
{
21
BOOTSTRAP
,
MMD2_SPECTRUM
,
MMD2_GAMMA
,
MMD1_GAUSSIAN
,
HSIC_GAMMA
22
};
23
41
class
CTestStatistic
:
public
CSGObject
42
{
43
public
:
44
CTestStatistic
();
45
46
virtual
~CTestStatistic
();
47
49
virtual
float64_t
compute_statistic
()=0;
50
60
virtual
float64_t
compute_p_value
(
float64_t
statistic)=0;
61
70
virtual
float64_t
compute_threshold
(
float64_t
alpha)=0;
71
77
virtual
SGVector<float64_t>
bootstrap_null
()=0;
78
83
virtual
void
set_bootstrap_iterations
(
index_t
bootstrap_iterations);
84
88
virtual
void
set_null_approximation_method
(
89
ENullApproximationMethod
null_approximation_method);
90
91
inline
virtual
const
char
*
get_name
()
const
=0;
92
93
private
:
94
void
init();
95
96
protected
:
98
index_t
m_bootstrap_iterations
;
99
101
ENullApproximationMethod
m_null_approximation_method
;
102
};
103
104
}
105
106
#endif
/* __TESTSTATISTIC_H_ */
SHOGUN
Machine Learning Toolbox - Documentation