
The longer Levin mowed, the oftener he felt the moments of unconsciousness in which it seemed not his hands that swung the scythe, but the scythe mowing of itself, a body full of life and consciousness of its own, and as though by magic, without thinking of it, the work turned out regular and well-finished of itself.
-- Tolstoy, Anna Karenina (trans. Constance Garnett)
The Scythe Statistical Library is an open source C++ library for statistical computation, written by Daniel Pemstein (North Dakota State University), Kevin M. Quinn (Emory University), and Andrew D. Martin (Washington University in St. Louis). It includes a suite of matrix manipulation functions, a suite of pseudo-random number generators, and a suite of numerical optimization routines. Programs written using Scythe are generally much faster than those written in commonly used interpreted languages, such as R and MATLAB, and can be compiled on any system with the GNU GCC compiler (and perhaps with other C++ compilers). One of the primary design goals of the Scythe developers has been ease of use for non-expert C++ programmers. We provide ease of use through three primary mechanisms: (1) operator and function over-loading, (2) numerous pre-fabricated utility functions, and (3) clear documentation and example programs. Additionally, Scythe is quite flexible and entirely extensible because the source code is available to all users under the GNU General Public License.
Current Public Release -- Scythe 1.0.3
We released Scythe 1.0 on January 15, 2007. This release represents a major overhaul of the library since the last public release (0.3) and the library's new interface is not backwards compatible with previous releases. Scythe now provides both column- and row-major matrices, multiple views of the same matrix, submatrix assignment, and a variety of other new functionality. In addition, Scythe now optionally uses highly optimized LAPACK and BLAS routines to perform certain matrix and linear algebra operations on machines that provide these libraries. Scythe 1.0.3, released on June 13, 2012, is more standards-compliant than previous releases, fixes a number of bugs, improves library efficiency, provides for thread safety, and enhances compatibility with the R Project for Statistical Computing. See the ChangeLog for details. We have tested Scythe 1.0.3 on Linux and OS X and the library should work with the GNU GCC compiler version 4.4.7 or greater.
Documentation
We currently provide an article that introduces the library and walks through some examples of how to use it, and a set of documents that exhaustively describe Scythe's application programmers' interface (API).
Projects and Papers That Use Scythe
Scythe has been used in the following software projects and published papers:
- MCMCpack by Andrew D. Martin and Kevin M. Quinn
- Matching by Jasjeet S. Sekhon
- Bayesian Filtering Library by Klass Gadeyne
- smoothSurv by Arnost Komarek
- MasterBayes by Jarrod Hadfield
- phcfM by Ghislain Vieilledent
- Cecere, S., Jara, A., and Lesaffre, E. 2006. "Analyzing the Emergence Times of Permanent Teeth: An Example of Modelling the Covariance Matrix with Interval-Censored Data." Statistical Modelling 6(4): 337-351.
- Kevin M. Quinn. 2004. "Bayesian Factor Analysis for Mixed Ordinal and Continuous Responses." Political Analysis 12: 338-353.
- Andrew D. Martin and Kevin M. Quinn. 2002. "Dynamic Ideal Point Estimation via Markov Chain Monte Carlo for the U.S. Supreme Court, 1953-1999." Political Analysis 10: 134-153.
- Stephen A. Meserve, Daniel Pemstein, and William T. Bernhard. "Political Ambition and Legislative Behavior in the European Parliament." 2009. Journal of Politics 71(3): 1015-1032
- Daniel Pemstein, Stephen A. Meserve, and James Melton. "Democratic Compromise: A Latent Variable Analysis of Ten Measures of Regime Type." 2010. Political Analysis 18(4): 426-449
- HADFIELD, J. D., RICHARDSON, D. S. and BURKE, T. 2006. "Towards unbiased parentage assignment: combining genetic, behavioural and spatial data in a Bayesian framework." Molecular Ecology 15: 3715-3730
- Abanto-Valle, C. A., Migon, H. S. and Lopes, H. F. 2010. "Bayesian modeling of financial returns: A relationship between volatility and trading volume." Applied Stochastic Models in Business and Industry 26: 172-193
- C.A. Abanto-Valle, D. Bandyopadhyay, V.H. Lachos, I. Enriquez. 2010. "Robust Bayesian analysis of heavy-tailed stochastic volatility models using scale mixtures of normal distributions." Computational Statistics & Data Analysis 54(12): 2883-2898
- Roos Leroy, Silvia Cecere, Emmanuel Lesaffre, Dominique Declerck. 2009. "Caries experience in primary molars and its impact on the variability in permanent tooth emergence sequences." Journal of Dentistry 37(11): 865-871
- Michael D. Schneider, Lloyd Knox, Salman Habib, Katrin Heitmann, David Higdon, and Charles Nakhleh. 2008. "Simulations and cosmological inference: A statistical model for power spectra means and covariances." Physical Review D 78(6): 063529
- Vieilledent, G., Grinand, C. and Vaudry, R. 2013. "Forecasting deforestation and carbon emissions in tropical developing countries facing demographic expansion: a case study in Madagascar." Ecology and Evolution. doi: 10.1002/ece3.550
Please let us know of other projects or papers to add to this list.
If you have any questions about Scythe, or would like to contribute to the project, please do not hesitate to email one of the authors: Daniel Pemstein, Kevin M. Quinn, or Andrew D. Martin.
Acknowledgements
We gratefully acknowledge support from the United States National Science Foundation (Grants SES-0350646 and SES-0350613), the Department of Political Science, the Weidenbaum Center, and the Center for Empirical Research in the Law at Washington University, and the Department of Government and The Institute for Quantitative Social Science at Harvard University. Neither the foundation, Washington University, the University of Michigan, nor Harvard University bear any responsibility for this software.
We'd also like to thank the research assistants who have helped us with Scythe: Matthew Fasman, Steve Haptonstahl, Kate Jensen, Laura Keys, Kevin Rompala, Joe Sheehan, and Jean Yang.