emcee swMATH ID: 20217 Software Authors: Daniel Foreman-Mackey, David W. Hogg, Dustin Lang, Jonathan Goodman Description: emcee: The MCMC Hammer. We introduce a stable, well tested Python implementation of the affine-invariant ensemble sampler for Markov chain Monte Carlo (MCMC) proposed by Goodman & Weare (2010). The code is open source and has already been used in several published projects in the astrophysics literature. The algorithm behind emcee has several advantages over traditional MCMC sampling methods and it has excellent performance as measured by the autocorrelation time (or function calls per independent sample). One major advantage of the algorithm is that it requires hand-tuning of only 1 or 2 parameters compared to ∼N2 for a traditional algorithm in an N-dimensional parameter space. In this document, we describe the algorithm and the details of our implementation and API. Exploiting the parallelism of the ensemble method, emcee permits any user to take advantage of multiple CPU cores without extra effort. The code is available online at http://dan.iel.fm/emcee/current/ under the MIT License. Homepage: http://dan.iel.fm/emcee/current/ Related Software: Python; SciPy; Matplotlib; NumPy; corner.py; CAMB; Astropy; PyMC; Rtwalk; t-walk; GetDist; dynesty; Scikit; Stan; Numba; Jupyter; IPython; Lightkurve; VEGAS; VEGAS+ Cited in: 37 Publications all top 5 Cited by 108 Authors 3 Weare, Jonathan Quincy 2 Bell, John B. 2 Morzfeld, Matthias 2 Oddo, Andrea 2 Porciani, Cristiano 2 Sefusatti, Emiliano 1 Adami, Kristian Zarb 1 Adshead, Peter 1 Aich, Arkajit 1 Alawieh, Leen 1 Alsing, Justin 1 Anagnostopoulos, Fotios K. 1 Ansoldi, Stefano 1 Argüelles, Carlos A. 1 Aviles, Alejandro 1 Baker, Tessa 1 Banerjee, Arka 1 Barreira, Alexandre 1 Basilakos, Spyros 1 Batista, R. C. 1 Bayen, Térence 1 Bergner, Georg 1 Bora, Kamal 1 Bose, Benjamin 1 Byun, Joyce 1 Carpio, Ana 1 Carrilho, Pedro 1 Charnock, Tom 1 Day, Marcus S. 1 de Felice, Antonio 1 de Putter, Roland 1 de Souza, Rafael S. 1 de Sturler, Eric 1 Desai, Shantanu 1 Dinner, Aaron R. 1 Doré, Olivier 1 Dufays, Arnaud 1 Finsterle, Stefan A. 1 García-Aspeitia, Miguel A. 1 Giacomello, Francesco 1 Gleyzes, Jérôme 1 Gong, Jing 1 Goodman, Jonathan B. 1 Grout, Ray W. 1 Harrison, Ian 1 Hernández-Almada, A. 1 Hilbe, Joseph Michael 1 Holanda, R. F. L. 1 Iakunin, Sergei 1 Ishida, Emille E. O. 1 Kandasamy, Kirthevasan 1 Kilmer, Misha Elena 1 Kim, Minchul 1 Kofinas, Georgios 1 Koten, Brian Van 1 Lee, Jaeyong 1 Leimkuhler, Benedict J. 1 Leon, Genly 1 Lepage, G. Peter 1 Li, Li 1 Lindsey, Michael 1 Lozanov, Kaloian D. 1 Magaña, Juan A. 1 Mairet, Francis 1 Makinen, T. Lucas 1 Markovič, Katarina 1 Marzouk, Youssef M. 1 Matthews, Charles E. 1 Medeiros, L. G. 1 Mendonça, I. E. C. R. 1 Mifsud, Jurgen 1 Miller, Eric L. 1 Monaco, Pierluigi 1 Moretti, Chiara 1 Niz, Gustavo 1 Pardo, Kris 1 Parkinson, David 1 Pau, George Shu Heng 1 Póczos, Barnabás 1 Pordeus-da-Silva, G. 1 Pourtsidou, Alkistis 1 Prasad, Pranjal 1 Rizzo, Federico 1 Rombouts, Jeroen V. K. 1 Saibaba, Arvind Krishna 1 Said, Jackson Levi 1 Saridakis, Emmanuel N. 1 Schaich, David 1 Schneider, Jeff 1 Shaposhnikov, Mikhail 1 Shields, Michael D. 1 Shkerin, Andrey 1 Slepian, Zachary 1 Stadler, Georg 1 Sultana, Joseph 1 Thiede, Erik H. 1 Timiryasov, Inar 1 Tong, Xin Thomson 1 Verdugo, Tomás 1 Wandelt, Benjamin D. ...and 8 more Authors all top 5 Cited in 15 Serials 18 Journal of Cosmology and Astroparticle Physics 3 Journal of Computational Physics 2 Journal of High Energy Physics 2 SIAM/ASA Journal on Uncertainty Quantification 1 Artificial Intelligence 1 Classical and Quantum Gravity 1 Computer Methods in Applied Mechanics and Engineering 1 Inverse Problems 1 Physica A 1 Journal of Econometrics 1 Journal of Statistical Planning and Inference 1 SIAM Journal on Scientific Computing 1 Journal of the Korean Statistical Society 1 Statistics and Computing 1 Journal of Theoretical Biology all top 5 Cited in 22 Fields 21 Relativity and gravitational theory (83-XX) 15 Statistics (62-XX) 11 Numerical analysis (65-XX) 11 Quantum theory (81-XX) 8 Partial differential equations (35-XX) 6 Optics, electromagnetic theory (78-XX) 5 Probability theory and stochastic processes (60-XX) 5 Computer science (68-XX) 5 Mechanics of particles and systems (70-XX) 5 Astronomy and astrophysics (85-XX) 3 Operator theory (47-XX) 2 Commutative algebra (13-XX) 2 Differential geometry (53-XX) 2 Fluid mechanics (76-XX) 2 Statistical mechanics, structure of matter (82-XX) 1 General algebraic systems (08-XX) 1 Calculus of variations and optimal control; optimization (49-XX) 1 Manifolds and cell complexes (57-XX) 1 Global analysis, analysis on manifolds (58-XX) 1 Classical thermodynamics, heat transfer (80-XX) 1 Game theory, economics, finance, and other social and behavioral sciences (91-XX) 1 Biology and other natural sciences (92-XX) Citations by Year