This program calculates a hybrid index for individuals of unknown ancestry. The index is based on information from molecular markers and uses maximum-likelihood to estimate the proportion of alleles that were inherited from one of two hybridizing parental species.

The index is defined for dominant and codominant molecular markers.

Citation: Buerkle, C. Alex. 2005. Maximum-likelihood estimation of a hybrid index based on molecular markers. Molecular Ecology Notes 5: 684-687 (abstract).

Estimate of hybrid index of a heterozygous


  • 13 July 07 -- added a Perl script to this page that will convert from STRUCTURE input format to the files required for hindex.
  • 5 Oct 05 -- Release of version 1.42. Text files for input can now have file endings from any operating system. Made two improvements to test for the absence of maximum estimates for hybrid index in the case of entirely missing or uninformative data. Program now returns "nan" (not a number) if no estimate can be calculated.
  • 14 Sept 05 -- updated README.txt to indicate that the text files for input should have Windows or UNIX line endings. This requirement has been removed in the pending release.
  • 23 May 05 -- Release of version 1.41. This release fixes a small bug in the checks on input data in the parental file. The bug does not affect estimates.
  • 12 October 04 -- Release of version 1.4. First release of graphical user interface for OS X and linux (x86). Some bug fixes.
  • 28 September 04 -- Release of version 1.3. Various bug fixes. Output to text file has better formatting. Graphical user interface is being developed.
  • 27 October 03 -- Changed input of parental frequencies for codominant data. Program now expects allele frequencies. Updated README.txt to reflect changes. Changed version number to 1.2.
  • 20 October 03 -- Binaries and source code updated to version 1.1 and released. Handling of dominant markers is now as described in papers by Rieseberg et al (1998, 1999).
  • 22 September 03 -- Binaries removed temporarily while I revise the likelihood function for dominant markers.
  • 23 June 03 -- Version 1.0 released. This is an initial release and I expect to add features that will make it more usable in the coming weeks. The software works and will provide maximum-likelihood estimates and support limits.

The program will fall over and fail with improper data input. I will continue to work on having the software catch input errors and provide useful error messages. Feedback to me would be helpful in this effort.

Distribution, installation and usage

hindex is a program that has a simple graphical user interface. I provide compiled binaries for OS X and linux-x86. Users of other systems can compile the program for themselves. Please note that the functionality of this software is now included in our R-package introgress, which means that the calculation can be done on all operating systems.

Download the desired file and decompress it. The application is double-clickable on OS X and can be started from the command-line under linux.
Source code (C++)

Compiling from source requires the GNU Scientific Library, which is a freely available library that contains numerical functions used by hindex (e.g., minimization and root-finding methods).

The graphical user interface is written in Tcl/Tk and compilation of the C++ code requires Tcl/Tk development files. Tcl/Tk components are typically included in Linux distributions.

A file with some information about working with the source is included (COMPILE.txt).

Related code

struct2hindex.pl -- A Perl program that takes a STRUCTURE input file and will generate corresponding input files for hindex. This is meant as an aid to users who are comfortable using Perl, not as a solution for all users.

All of the archives include sample input data for individual genotypes (individual.txt) and parental allele frequencies (parental.txt). These should be used as examples for how to code input data. See the README file for details.

Terms of use

The software is available for use under the GNU Public License (GPL). This means it is free to use. You are encouraged to download the source code, review it, and improve it. If you use parts of the code in software of your own, you are required to give your users the same rights that were granted to you under the GPL.

Note that under the GPL, the software is distributed without warranty.

I request that you cite the article if you use the software in analyses that appear in print.

If you use hindex, please send me an email so that I can notify users when I release new versions of the software. Additionally, please send me your requests for additional features and bug reports.