barry: Your go-to motif accountant  0.0-1
Full enumeration of sample space and fast count of sufficient statistics for binary arrays
StatsCounter< Array_Type, Data_Type > Class Template Reference

Count stats for a single Array. More...

#include <statscounter-bones.hpp>

Public Member Functions

 StatsCounter (const Array_Type *Array_)
 Creator of a StatsCounter More...
 
 StatsCounter (const StatsCounter< Array_Type, Data_Type > &counter)
 Copy constructor. More...
 
 StatsCounter ()
 Can be created without setting the array. More...
 
 ~StatsCounter ()
 
void reset_array (const Array_Type *Array_)
 Changes the reference array for the counting. More...
 
void add_counter (Counter< Array_Type, Data_Type > f_)
 
void set_counters (Counters< Array_Type, Data_Type > *counters_)
 
void count_init (size_t i, size_t j)
 Counter functions This function recurses through the entries of Array and at each step of adding a new cell it uses the functions to list the statistics. More...
 
void count_current (size_t i, size_t j)
 
std::vector< double > count_all ()
 
Counters< Array_Type, Data_Type > * get_counters ()
 
std::vector< std::string > get_names () const
 
std::vector< std::string > get_descriptions () const
 
size_t size () const
 

Detailed Description

template<typename Array_Type, typename Data_Type>
class StatsCounter< Array_Type, Data_Type >

Count stats for a single Array.

Users can a list of functions that can be used with this. The baseline set of arguments is a pointer to a binary array and a dataset to add the counts to.

Definition at line 14 of file statscounter-bones.hpp.

Constructor & Destructor Documentation

◆ StatsCounter() [1/3]

template<typename Array_Type , typename Data_Type >
StatsCounter< Array_Type, Data_Type >::StatsCounter ( const Array_Type *  Array_)
inline

Creator of a StatsCounter

Parameters
Array_A const pointer to a BArray.

Definition at line 37 of file statscounter-bones.hpp.

◆ StatsCounter() [2/3]

template<typename Array_Type , typename Data_Type >
StatsCounter< Array_Type, Data_Type >::StatsCounter ( const StatsCounter< Array_Type, Data_Type > &  counter)

Copy constructor.

Parameters
counter

◆ StatsCounter() [3/3]

template<typename Array_Type , typename Data_Type >
StatsCounter< Array_Type, Data_Type >::StatsCounter ( )
inline

Can be created without setting the array.

Definition at line 59 of file statscounter-bones.hpp.

◆ ~StatsCounter()

template<typename Array_Type , typename Data_Type >
StatsCounter< Array_Type, Data_Type >::~StatsCounter ( )

Member Function Documentation

◆ add_counter()

template<typename Array_Type , typename Data_Type >
void StatsCounter< Array_Type, Data_Type >::add_counter ( Counter< Array_Type, Data_Type >  f_)

◆ count_all()

template<typename Array_Type , typename Data_Type >
std::vector< double > StatsCounter< Array_Type, Data_Type >::count_all
inline

Definition at line 99 of file statscounter-meat.hpp.

◆ count_current()

template<typename Array_Type , typename Data_Type >
void StatsCounter< Array_Type, Data_Type >::count_current ( size_t  i,
size_t  j 
)

◆ count_init()

template<typename Array_Type , typename Data_Type >
void StatsCounter< Array_Type, Data_Type >::count_init ( size_t  i,
size_t  j 
)

Counter functions This function recurses through the entries of Array and at each step of adding a new cell it uses the functions to list the statistics.

◆ get_counters()

template<typename Array_Type , typename Data_Type >
Counters<Array_Type,Data_Type>* StatsCounter< Array_Type, Data_Type >::get_counters ( )

◆ get_descriptions()

template<typename Array_Type , typename Data_Type >
std::vector< std::string > StatsCounter< Array_Type, Data_Type >::get_descriptions ( ) const

◆ get_names()

template<typename Array_Type , typename Data_Type >
std::vector< std::string > StatsCounter< Array_Type, Data_Type >::get_names ( ) const

◆ reset_array()

template<typename Array_Type , typename Data_Type >
void StatsCounter< Array_Type, Data_Type >::reset_array ( const Array_Type *  Array_)

Changes the reference array for the counting.

Parameters
Array_A pointer to an array of class Array_Type.

◆ set_counters()

template<typename Array_Type , typename Data_Type >
void StatsCounter< Array_Type, Data_Type >::set_counters ( Counters< Array_Type, Data_Type > *  counters_)

◆ size()

template<typename Array_Type , typename Data_Type >
size_t StatsCounter< Array_Type, Data_Type >::size ( ) const
inline

Definition at line 86 of file statscounter-bones.hpp.


The documentation for this class was generated from the following files: