LArDiscreteProbabilityHelper class.
More...
#include "LArDiscreteProbabilityHelper.h"
|
template<typename T > |
static float | CalculateCorrelationCoefficientPValueFromPermutationTest (const T &t1, const T &t2, std::mt19937 &randomNumberGenerator, const unsigned int nPermutations) |
| Calculate P value for measured correlation coefficient between two datasets via a permutation test.
|
|
template<typename T > |
static float | CalculateCorrelationCoefficientPValueFromStudentTDistribution (const T &t1, const T &t2, const unsigned int nIntegrationSteps, const float upperLimit) |
| Calculate P value for measured correlation coefficient between two datasets via a integrating the student T dist.
|
|
template<typename T > |
static float | CalculateCorrelationCoefficient (const T &t1, const T &t2) |
| Calculate the correlation coefficient between two datasets.
|
|
template<typename T > |
static float | CalculateMean (const T &t) |
| Calculate the mean of a dataset.
|
|
|
template<typename T > |
static T | MakeRandomisedSample (const T &t, std::mt19937 &randomNumberGenerator) |
| Make a randomised copy of a dataset.
|
|
template<typename T > |
static std::vector< T > | MakeRandomisedSample (const std::vector< T > &t, std::mt19937 &randomNumberGenerator) |
| Make a randomised copy of dataset (dataset is an std::vector)
|
|
template<typename T > |
static unsigned int | GetSize (const T &t) |
| Get the size the size of a dataset.
|
|
template<typename T > |
static unsigned int | GetSize (const std::vector< T > &t) |
| Get the size of a dataset (dataset is an std::vector)
|
|
template<typename T > |
static float | GetElement (const T &t, const unsigned int index) |
| Get an element in a dataset.
|
|
template<typename T > |
static float | GetElement (const std::vector< T > &t, const unsigned int index) |
| Get an element in a dataset (dataset is an std::vector)
|
|
◆ CalculateCorrelationCoefficient()
template<typename T >
template float lar_content::LArDiscreteProbabilityHelper::CalculateCorrelationCoefficient |
( |
const T & |
t1, |
|
|
const T & |
t2 |
|
) |
| |
|
static |
Calculate the correlation coefficient between two datasets.
- Parameters
-
t1 | the first input dataset |
t2 | the second input dataset |
- Returns
- the correlation coefficient
Definition at line 74 of file LArDiscreteProbabilityHelper.cc.
◆ CalculateCorrelationCoefficientPValueFromPermutationTest()
template<typename T >
template float lar_content::LArDiscreteProbabilityHelper::CalculateCorrelationCoefficientPValueFromPermutationTest |
( |
const T & |
t1, |
|
|
const T & |
t2, |
|
|
std::mt19937 & |
randomNumberGenerator, |
|
|
const unsigned int |
nPermutations |
|
) |
| |
|
static |
Calculate P value for measured correlation coefficient between two datasets via a permutation test.
- Parameters
-
t1 | the first input dataset |
t2 | the second input dataset |
randomNumberGenerator | the random number generator to shuffle the datasets |
nPermutations | the number of permutations to run |
- Returns
- the p-value
Definition at line 16 of file LArDiscreteProbabilityHelper.cc.
◆ CalculateCorrelationCoefficientPValueFromStudentTDistribution()
template<typename T >
template float lar_content::LArDiscreteProbabilityHelper::CalculateCorrelationCoefficientPValueFromStudentTDistribution |
( |
const T & |
t1, |
|
|
const T & |
t2, |
|
|
const unsigned int |
nIntegrationSteps, |
|
|
const float |
upperLimit |
|
) |
| |
|
static |
Calculate P value for measured correlation coefficient between two datasets via a integrating the student T dist.
- Parameters
-
t1 | the first input dataset |
t2 | the second input dataset |
nIntegrationSteps | how many steps to use in the trapezium integration |
upperLimit | the upper limit of the integration |
- Returns
- the p-value
Definition at line 41 of file LArDiscreteProbabilityHelper.cc.
◆ CalculateMean()
template<typename T >
template float lar_content::LArDiscreteProbabilityHelper::CalculateMean |
( |
const T & |
t | ) |
|
|
static |
◆ GetElement() [1/3]
template<>
float lar_content::LArDiscreteProbabilityHelper::GetElement |
( |
const DiscreteProbabilityVector & |
t, |
|
|
const unsigned int |
index |
|
) |
| |
|
inline |
◆ GetElement() [2/3]
template<typename T >
float lar_content::LArDiscreteProbabilityHelper::GetElement |
( |
const std::vector< T > & |
t, |
|
|
const unsigned int |
index |
|
) |
| |
|
inlinestaticprivate |
Get an element in a dataset (dataset is an std::vector)
- Parameters
-
t | the std::vector dataset |
index | the index of the element |
- Returns
- the std::vector-based dataset element
Definition at line 174 of file LArDiscreteProbabilityHelper.h.
◆ GetElement() [3/3]
template<typename T >
static float lar_content::LArDiscreteProbabilityHelper::GetElement |
( |
const T & |
t, |
|
|
const unsigned int |
index |
|
) |
| |
|
staticprivate |
Get an element in a dataset.
- Parameters
-
t | the dataset |
index | the index of the element |
- Returns
- the dataset element
◆ GetSize() [1/3]
◆ GetSize() [2/3]
template<typename T >
unsigned int lar_content::LArDiscreteProbabilityHelper::GetSize |
( |
const std::vector< T > & |
t | ) |
|
|
inlinestaticprivate |
Get the size of a dataset (dataset is an std::vector)
- Parameters
-
- Returns
- the std::vector-based dataset size
Definition at line 160 of file LArDiscreteProbabilityHelper.h.
◆ GetSize() [3/3]
template<typename T >
static unsigned int lar_content::LArDiscreteProbabilityHelper::GetSize |
( |
const T & |
t | ) |
|
|
staticprivate |
Get the size the size of a dataset.
- Parameters
-
- Returns
- the dataset size
◆ MakeRandomisedSample() [1/3]
◆ MakeRandomisedSample() [2/3]
template<typename T >
std::vector< T > lar_content::LArDiscreteProbabilityHelper::MakeRandomisedSample |
( |
const std::vector< T > & |
t, |
|
|
std::mt19937 & |
randomNumberGenerator |
|
) |
| |
|
inlinestaticprivate |
Make a randomised copy of dataset (dataset is an std::vector)
- Parameters
-
t | the std::vector-based dataset to be shuffled |
randomNumberGenerator | the random number generator |
- Returns
- the reshuffled std::vector
Definition at line 143 of file LArDiscreteProbabilityHelper.h.
◆ MakeRandomisedSample() [3/3]
template<typename T >
static T lar_content::LArDiscreteProbabilityHelper::MakeRandomisedSample |
( |
const T & |
t, |
|
|
std::mt19937 & |
randomNumberGenerator |
|
) |
| |
|
staticprivate |
Make a randomised copy of a dataset.
- Parameters
-
t | the dataset to be shuffled |
randomNumberGenerator | the random number generator |
- Returns
- the reshuffled dataset
The documentation for this class was generated from the following files: