Introduction to the Haplotype Frequency Estimation System (HFES)

To obtain this program, please contact the author.

You can also download a self-extrating archive of HFES (PC version) from here.


HFES is a package of computer programs for estimating allele and haplotype frequencies. HFES uses the algorithm of 'gene counting', so that the maximum likelihood estimates of frequencies are obtained. All the programs are written for Turbo Pascal compiler (ver. 5.5 or higher; Borland International). If you intend to compile these programs by other Pascal compilers, you may have to modify some parts of the programs. In particular, the way of open/close of files varies among compilers.

In this system, allele and haplotype frequencies are calculated by executing a series of programs. First of all, the raw data is transformed to POPULALL.DAT by PROCESS.PAS. Note that PROCESS.PAS uses standard input. To use the program, compile it and then type 'PROCESS < sample.dat' after the prompt. If no warning message appeared, then execute 'HP1', 'HP2', 'HP3', 'HP4', 'HP5', 'LKD2', 'LKD3', 'LKD4' and 'LKD5.'

If available memory on your computer is limited, constants such as MNALL, MNHAP and MNPHE should be changed as small as possible. Otherwise, HP4.PAS and HP5.PAS may terminate abnormally.

These programs can be applied not only to HLA loci but also any codominant loci. When applied to a co-dominant locus without a recessive allele such as complement locus BF, the procedure 'DelHomo' in PROCESS.PAS should be modified. See the program PROCESS.PAS for more explanations.

You can freely modify and use these programs without permission of the original author. However, if very useful modifications are made on these programs, please send them to the author.

The following is a blief explanation for each of the programs.

PROCESS.PAS --- transforms an original data file to POPULALL.DAT 
	according to the information written in INFORM.DOC.
	Input: INFORM.DOC and standard input.
	Output: POPULALL.DAT.

HP1.PAS --- calculates the ML estimates of allele frequencies.
	Input: INFORM.DOC and POPULALL.DAT.
	Output: AF.RES and SUM_1.DAT.

HP2.PAS --- calculates the ML estimates of two-locus haplotype frequencies.
	Input: INFORM.DOC and POPULALL.DAT.
	Output: HF2.RES and SUM_2.DAT.

HP3.PAS --- calculates the ML estimates of three-locus haplotype 
	frequencies.
	Input: INFORM.DOC and POPULALL.DAT.
	Output: HF3.RES and SUM_3.DAT.

HP4.PAS --- calculates the ML estimates of four-locus haplotype 
	frequencies.
	Input: INFORM.DOC and POPULALL.DAT.
	Output: HF4.RES and SUM_4.DAT.

HP5.PAS --- calculates the ML estimates of five-locus haplotype 
	frequencies.
	Input: INFORM.DOC and POPULALL.DAT.
	Output: HF5.RES and SUM_5.DAT.

LKD2.PAS --- calculates the values of linkage disequilibrium for two-locus 
	haplotypes.  LD (linkage disequilibrium), RLD (relative linkage 
	disequilibrium) and ChiSQ (chi-square value) are calculated.
	Input: INFORM.DOC, SUM_1.DAT and SUM_2.DAT.
	Output: LD2.RES.

LKD3.PAS --- calculates the values of linkage disequilibrium (LD) for 
	three-locus haplotypes.
	Input: INFORM.DOC, SUM_1.DAT and SUM_3.DAT.
	Output: LD3.RES.

LKD4.PAS --- calculates the values of linkage disequilibrium (LD) for 
	four-locus haplotypes.
	Input: INFORM.DOC, SUM_1.DAT and SUM_4.DAT.
	Output: LD4.RES.

LKD5.PAS --- calculates the values of linkage disequilibrium (LD) for 
	five-locus haplotypes.
	Input: INFORM.DOC, SUM_1.DAT and SUM_5.DAT.
	Output: LD5.RES.

GOHFES.BAT --- a batch program that executes all above programs.

A set of sample data and the results of calculation is located in the 
directory SAMPLE.  They will help you to understand how to use HFES 
programs.



	April 11, 1992

	Tadashi Imanishi
	Center for Information Biology, National Institute of Genetics
	Mishima, Shizuoka 411-8540, Japan
	E-mail address: timanish@genes.nig.ac.jp