barry: Your go-to motif accountant
0.0-1
Full enumeration of sample space and fast count of sufficient statistics for binary arrays
|
This repository contains a C++ template library that essentially counts sufficient statistics on binary arrays. Its primary goal is to provide a general framework for building discrete exponential-family models. A particular example is Exponential Random Graph Models (ERGMs), but we can use barry
to deal with non-square arrays.
Among the key features included in barry
, we have:
To use barry, you can either download the entire repository or, since it is header-only, the single header version barry.hpp
.
This library was created and maintained by Dr. George G. Vega Yon as part of his doctoral dissertation "Essays on Bioinformatics and Social Network Analysis: Statistical and Computational Methods for Complex Systems."
In the following code we create an array of size 5x5 of class Network
(available in the namespace netcounters), add/remove ties, print the graph, and count common statistics used in ERGMs:
Compiling this program using g++
Yields the following output:
One of the key features of barry
is that it will handle memory efficiently. In the case of pooled-data models, the module for statistical models avoids double-counting support when possible by keeping track of what datasets (networks, for instance) share the same.
More information can be found in the Doxygen website here and in the PDF version of the documentation here.
Please note that the barry
project is released with a Contributor Code of Conduct. By contributing to this project, you agree to abide by its terms.