TABLE.DOC

Version history

December 2004 v1.8

Minor change to output to make table file readable by Excel. 

Compiled with MSVC


November 1998 v1.7

Dropped support for B-test, Liang test. Added support for gnuplot.


June 1996 v1.1

Use - for command line switches under MSDOS as well as Unix. 

TABLE now reports which files it is writing.



Documentation for TABLE.EXE

This is a very simple program which takes the output from MLINK 
or LINKMAP and tabulates it in a more easily digestible form. It 
can also produce files suitable for graphing lod scores and for 
input to HOMOG, BTEST and FASTMAP. 

The input file is the OUTPUT.DAT file which the LINKAGE programs 
produce. When using LINKSYS or DOLINK this file is renamed to be 
FILENAME.RES. With LCP or the LINKSYS program MCP it is possible 
to run a whole load of analyses all at once and output them into 
one results file. If you do this TABLE will not work correctly - 
it expects to find the output from only one analysis by either 
LINKMAP or MLINK. If you have set up a batch file to run several 
analyses at once, you must edit the output so that the result of 
each analysis is in a different .RES file. TABLE has actually only 
been tested with the results files produced by LINKSYS v. 4.11 and 
LINKAGE v. 4.7 and 5. With LINKMAP it assumes that the test locus 
is named first and that the whole map has been produced. With 
MLINK it assumes that the "lod score table" output option has been 
selected. TABLE may work in other circumstances - I just haven't 
tried it. 

If you are working with more than one pedigree at a time then 
make sure that the "byfamily" switch in the LINKAGE programs is 
set to true so that likelihood values are output for each family 
- it will not increase the time that it takes the program to 
run. Otherwise only the total lod scores across pedigrees will 
be available. 

In the documentation below files and the name of the TABLE 
program are given in upper case for clarity, but really they 
would be in lower case under Unix. Under MSDOS case is ignored.

If your results have ended up in FILENAME.RES then to use TABLE 
just enter:

TABLE FILENAME.RES

A new file will be created on your disk called FILENAME.TAB. 
This contains a table of lod scores at different recombination 
frequencies, or with LINKMAP at different distances taking 
distance 0 to be at 0% recombination with the leftmost fixed 
marker. The lod scores are calculated by subtracting the log10 
likelihood at theta=50% from the log10 likelihood at other 
recombination fractions. Reombination fractions are converted to 
distances in centimorgans using the Kosambi mapping function.

There are seven optional switches which can be used with TABLE 
to produce other files: 

table filename -g -h -a[val] -i -x -p

(Under MSDOS the file will be assumed to have 
extension .RES, and this extension can be omitted.)

If -g is selected a file called FILENAME.GRP will be created. 
This provides the input for a shareware graphing program 
available from me called EASIGRAF, which forms part of the 
EASISTAT package. To see the graph of lod scores one simply 
enters: 

EASIGRAF FILENAME.GRP

If -x is selected a file called FILENAME.XGR will be created. 
This is a graph file for the ACE/gr graphing program, which 
runs on workstations and terminals using X. Run the 
program (called xvgr or xmgr) and select the "Read sets" command 
from the "File" menu. Read in the file (FILENAME.XGR). Click on 
the autoscale button (AS) and the graph of lod scores should be 
displayed. ACE/gr was written by Paul Turner and is available in 
source form from ftp.ccalmr.ogi.edu in CCALMR/pub/acegr.

If -p is selected files called FILENAME.PLT and FILENAME.GDA are 
created for use by the publicly available graph-drawing program 
GNUPLOT. To display a graph using these files, from GNUPLOT select 
File, Open and then choose FILENAME.PLT. The plotting commands in 
FILENAME.PLT should draw an appropriate graph from the data in 
FILENAME.GDA.

If -h is selected a file called FILENAME.HOM is produced which 
can be read in by Jurg Ott's HOMOG program to perform the A-test 
of homogeneity of linkage. (See Ott, 1985 Analysis of Human 
Genetic Linkage, John Hopkins University Press and Ott, Ann Hum 
Genet 47:311-320, 1983). A version of the program is available 
from Jurg Ott but unfortunately this no longer uses the same 
format as the listing in the book so some editing would be 
necessary. The source code for a version transcribed into C 
which uses the original format is included together with the 
executable. 

If -a is selected then the TABLE program itself performs the A-
test calculations. It outputs the adjusted lod score (log 10 of 
the likelihood ratio) obtained under the assumption of 
heterogeneity, called lod2 by Risch, together with alpha, the 
fraction of linked families which produce this maximum lod. It 
does not explicitly perform the test for statistical 
significance which the original HOMOG program does. To do this 
by hand, subtract the maximum conventional (total) lod from the 
maximum value of A-lod and multiply by 2ln(10) (twice the 
natural log of 10, about 4.605). According to Ott's original
account, this may be taken as a chi-squared statistic with one 
degree of freedom providing evidence to support the hypothesis 
of heterogeneity if linkage is assumed. It is also possible to 
supply a fixed value for alpha, in which case the adjusted lod 
will be calculated assuming that the given fraction of families 
is linked (otherwise the TABLE program searches for the value of 
alpha which yields the maximum lod score). To supply a fixed 
value for alpha, enter it directly after the -a switch, e.g. 
-a0.5, -a0.8. Any number of fixed alpha values can be specified 
(up to the value of MAXALPHAS defined in the source code), 
as well as or instead of the -a switch on its own. The adjusted 
lod scores are appended to others in the table and graph files. 
However for reasons of clarity the graph file written for 
EASIGRAF will not be set up to display these adjusted lod scores 
by default. In order to have them displayed then either the 
graph files should be edited (to insert the relevant DATATYPE:XY 
lines) or else the Data menu can be used from within EASIGRAF. 

If -i is selected a file called FILENAME.INP is created which 
contains recombination fraction and lod score pairs as needed 
for input into the FASTMAP program. This produces estimates of 
multipoint lod scores from two-point scores as described in 
"Curtis D, Gurling HMD. A procedure for combining two-point 
lod scores into a summary multipoint map. Human Heredity 
1993 43 173-185." It is available from my ftp site at 
www.gene.ucl.ac.uk/~dcurtis/software.html

Note that to produce input for HOMOG the .RES file 
must (obviously) contain output from more than one pedigree and 
the likelihoods by family must be available. 

I hope people find this useful.

Dave Curtis    dcurtis@hgmp.mrc.ac.uk 
                                        January 2, 1996

   Joint Academic Department of Psychological Medicine
   London Hospital Medical College
   3rd Floor Alexandra Wing
   Turner Street
   London E1 2AD




