Genepop reference page

Genepop is now distributed as an R package on CRAN. This package includes the latest version of the Genepop C++ sources, currently version 4.6.9, from which a stand-alone executable can still be produced. You will find below the sources and instructions for this stand-alone version. Also available here is a recompiled version of the linkdos program (Garnier-Géré and Dillmann 1992), which was distributed with previous versions of Genepop. Linkdos is not part of Genepop itself.


Full distribution (checked with virustotal on 2017-06-26): download GenepopV4.tar.gz or

Documentation: download Genepop.pdf

Windows Executables (32 and 64-bit versions): download

Example files: download

Sources (Windows, Linux/MacOS; also linkdos source): download sources.tar.gz or

In case of problem with files obtained from this page, please report to me (not to Eleanor Morgan); and read the documentation first.

Credits and copyrights

The R package was developed in collaboration with Jimmy Lopez (MBB platform supported by Labex Cemeb) and Khalid Belkhir (ISE-M). J. Lopez maintains a git page (in French) for Genepop.

Genepop is freeware (i.e. you don't need to pay). It is free software covered by the CeCILL licence (GPL compatible), i.e. it can be used, copied, studied, modified and redistributed in other free software also covered by a GPL-compatible licence (in particular, with freely available source code, even if commercial software), and provided the Genepop source is acknowledged (of course... well, that does not seem obvious to everyone. See the GPL!). Rousset, 2008 is an appropriate reference for all versions of Genepop.

Change log

What is new to version 4.6.9? No new option introduced. The source code better conforms to recent C++ coding standards and was made suitable for compilation as a shared library. A compiler with c++11 capabilities is required.  Genepop now uses the implementation of the Mersenne twister pseudo-random number generator found in such compilers. The documentation sources were converted from LaTeX to Rmarkdown, which is more suitable for generating all formats of the documentation.

What is new to version 4.6?

A bootstrap analysis of mean differentiation has been introduced, in particular to allow comparison of differentiation over a given range of geographical distances, in intra vs. inter-ecotypic analyses. In can be called by the setting meanDifferentiationTest. The Mantel test based on regression slope (not the one on ranks) was not handling appropriately cases where some pairwise data had to be excluded (thanks again to T. de Meeus for pointing this). This is corrected.

What is new to version 4.5.1?

A bug was found and corrected in the Mantel test when performed after a bootstrap (thanks to Thierry de Meeus for spotting discrepancies between Mantel tests).

What is new to version 4.5?

A new keyword inter_all_pairs for setting "popTypeSelection" allows one to perform spatial regressions (but not Mantel tests) between all pairs of individuals or populations belonging to different types (e.g., individuals belonging to different patches, excluding pairwise statistics for pairs of individuals within patches). The inter-OS input file checks have been modfied (again), to address a persistent problem on Mac OS X.

What is new to version 4.4?

Mantel tests are by default no longer based on rank correlation of the distances, but instead on the correlation of the distances. The older rank tests can be performed using the new MantelRankTest setting. In addition, a MaximalDistance setting has been added, affecting the computation of spatial regressions in a way similar to MimimalDistance (but this new setting is best ignored in normal use).

What was new to version 4.3?

New options 8.5 to retain individual names when converting population data to individual data, and 8.6 for generation of haploid genotypes by random sampling in diploid genotypes. Much code tidying to avoid warnings with stricter compilers than vanilla g++..

Older changes since version (first advertised release):

4.2.2: Only a cryptic bug fix which won't change any Genepop output, and more changes to comply with the clang compiler stricter syntax checks.  4.2.1: More cryptic changes in input file checks (again). 4.2: One can perform all isolation-by-distance analyses with a user-provided distance matrix. Cryptic changes in inter-OS input file checks (again) and in the way locus names are read, which could previously make Genepop crash. 
4.1.4: Wrong files were included in version 4.1.3. This new release corrects for this. 4.1.3: This version intended to correct two problems with the IsolationFile option: the source file was not correctly read and (for Windows only) the results when not correctly displayed. 4.1.2: The Windows executables included in version 4.1.1 were not portable and this is corrected. The genotypic disequilibrium test treated incomplete genotypes as full genotypes and this is corrected. 4.1.1: Again some cryptic changes in inter-OS input file checks; correction of a crashing bug for a missing-data case in LD testing; but nothing really new in the code. 64-bit executables for Windows. (but see version 4.1.2) The LINKDOS.exe which was missing from the v.4.1 distribution, has been restored.
4.1: (1) It is possible to test trends in gene diversity among samples. (2) Analyses of isolation by distance have been strengthened in several ways. Variants of previously described estimators have been implemented for both haploid and diploid data. 0ne can select subsets of the data for analyses of isolation by distance within and between these subsets. Further, analysis of isolation by distance from several one-locus genetic distance matrices is now possible through the MultiMigFile option. In contrast to IsolationFile, this allows the construction of bootstrap confidence intervals. Finally, it is possible to test specific values of the slope of the spatial regression, using the testPoint setting. (3) The input file reading procedure is better protected against nonstandard file formats (in particular those produced by some Microsoft software under Mac OS X). (4) The new sub-option 8.4 has been added to convert population-based data to individual-based data (each individual in its own Pop).
v. 4.0.6 (05/09/2007): corrected a change in v. which made settings files unreadable under Windows. Sample file sampleSettings.txt also corrected to match the examples in the Documentation. v. 4.0.7 (25/11/2007): corrected a bug in the Mantel test when some samples had null geographic distance. v. 4.0.8 (28/01/2009): corrected a minor file reading bug in linkage disequilibrium test when pop strings were followed by tab characters. v. 4.0.9 (02/03/2009): can now convert 3-digits data to Linkdos format. v. 4.0.10 (28/04/2009): cosmetic changes + updating #include's for compilation with g++ 4.3.2. v. 4.0.11 (25/06/2010): corrected a bug (introduced in version 4) for computation of P-values from chi2 distribution with large df's. Also some more cryptic changes including new procedures for checking input file format, in principle less dependent on operating system distribution-specific features.

© François Rousset 2007-now