Modern Measures of Population Differentiation

Provides functions for measuring population divergence from genotypic data.

mmod is an R package for calculating modern population divergence statistics.



mmod is on CRAN, so you can install the latest stable version using install.packages("mmod"). This github repository may be running ahead of the version on CRAN, if you really want the latest version you can download mmod_*.tar.gz and install via the command line (or with the GUI if you'd prefer):

    $R CMD INSTALL mmod_*.tar.gz 

###Usage Once it's up an running all you need is genepop (or fstat) file with your data >my_data <- read.genepop("my_file.gen") >diff_stats(my_data)


Population geneticists have traditionally used Nei's Gst (often confusingly called Fst...) to measure divergence between populations. It turns out, Gst doesn't really measure divergence so, [a set of new measures have been developed] (

mmod is a package that brings two of these measures; Hedricks (2005, 2011) G''st Jost's (2008) D and Meirman's (2005) φ'st to R, along with a function that calculates Nei's Gst using nearly unbiased estimators for Hs and Ht (the two key parameters from which most of these stats are calculated). All these functions work on genind objects from the library adegenet so data can be read in from standard genepop for fstat files. An overview of a typical usage is provided in a vignette called "demo", acessable from vignette("demo", package="mmod"), I suggest new users read this before that start.

##Help All functions are documented, there are [pretty versions of the help pages here] (


*1.3.2 __

summarize_boostrap now provides normal method (obs +/- 1.96 * std. dev.) confidence intervals as well as percentile method. Normal method is used in print statement for summarized boostraps.

Small tweaks to match new CRAN policy/ R behaviour


Bug fix: Since the last release the pairwise version of Gst_Nei was actually caclulated Gst_Hedrick. Thanks to Thierry Gosselin for the patch.

*1.3.0 __

MMOD now compatible with adegenet 2.0.

Additional small changes

  • Option to use harmonic means of Hs/Ht in calculation of jost's D
  • Clean up of pairwise function code
  • explicit imports from stats pkg (new CRAN policy)

*1.2.1 __

Small Updates to keep up with best practices (devtools CRAN)

*1.2 __

New function to turn a DNAbin object (from ape) into a genind with frequency of haplotypes/alleles Implemented tests for stats functions Pairwise functions maintain their pop names (thanks Brend Gruber)

  • 1.01 __

Fixed bug in Gst_Nei, reported by Aaron Adamack Sped up dist.codom Create staticdocs documentation

1.0 __

Mainly small tweaks to existing tools Bumped to 1.0 as paper describing this software is out (CITATION included)

  • 0.3 __

Added Phi_st_Meirmans - a differentiation measure based on the AMOVA framework Extended the Vignette to include a small discussion on which stats mmod can and can't calculate and how to chose the right one for your study Caught some typos and made a number of small changes

  • 0.2.1 __

chao_boostrap now uses multinomial distribution to create samples (previously it resampled individuals) - this makes very little difference.

Discussion in chao_bootsrap's documentation about bias in bootstrapping procedure Significant speeding up of all functions by using base R as much as possible

  • 0.2 __

More documentation. Added a vignette to reproduce analysis for nancycats data

  • 0.1.1 __

First release on CRAN - bassic diff. stats including pairwise versions and exact test of differentiation.

Reference manual

It appears you don't have a PDF plugin for this browser. You can click here to download the reference manual.


1.3.3 by David Winter, 4 years ago

Report a bug at

Browse source code at

Authors: David Winter [aut, cre] , Peter Green [ctb] , Zhian Kamvar [ctb] , Thierry Gosselin [ctb]

Documentation:   PDF Manual  

MIT + file LICENSE license

Imports stats, pegas

Depends on adegenet

Suggests testthat

Imported by HierDpart, PopGenReport, dartR.

See at CRAN