The program for
the first greedy
algorithm:
 |
The first
greedy algorithm is implemented in Java. To run this program, you have to
first download the Java Development Kit (JDK) from
http://java.sun.com. You can compile the
Java sources and then run the program.
|
 |
Source code:
including RunG1.java and Greedy1.java.
|
 |
Java classes:
you can skip the compiling process by running these classes directly.
|
 |
Input file
format: BlockID haplotype_frequence haplotype_pattern (see an
example). For the haplotype patterns,
we represent the major allele as 1, the minor allele as 0, and the missing
allele as n. The following is an input file of two haplotype blocks, each of
them contains 2 haplotype patterns with 7 SNPs.
 |
Block1 2
1100110
|
 |
Block1 1
11110n0
|
 |
Block2 4
1100101
|
 |
Block2 3
11n0101
|
|
 |
Running this program
requires two input parameters.
 |
Parameter 1:
the number of missing SNPs allowed.
|
 |
Parameter 2:
the input file containing haplotype blocks.
|
|
 |
For example,
if you wanna tolerate 3 missing SNPs and the input file is test.dat. In the
command line, please type
 |
java RunG1 3
test.dat
|
 |
An output
file "Greedy1_3.txt" containing the robust tag SNPs for each block is
generated.
|
|
The program for
the second
greedy algorithm:
 |
The second
greedy algorithm is implemented in Java. To run this program, you have to
first download the Java Development Kit (JDK) from
http://java.sun.com. You can compile the
Java sources and then run the program.
|
 |
Source code:
including RunG2.java and
Greedy2.java.
|
 |
Java classes:
you can skip the compiling process by running these classes directly.
|
 |
Input file
format: BlockID haplotype_frequence haplotype_pattern (see an
example). For the haplotype patterns,
we represent the major allele as 1, the minor allele as 0, and the missing
allele as n. The following is an input file of two haplotype blocks, each of
them contains 2 haplotype patterns with 7 SNPs.
 |
Block1 2
1100110
|
 |
Block1 1
11n1000
|
 |
Block2 4
1100101
|
 |
Block2 3
110010n
|
|
 |
This program
requires two input parameters.
 |
Parameter 1:
the number of missing SNPs allowed.
|
 |
Parameter 2:
the input file containing haplotype blocks.
|
|
 |
For example,
if you wanna tolerate 3 missing SNPs and the input file is test.dat. In the
command line, please type
 |
java RunG2 3
test.dat
|
 |
An output
file "Greedy2_3.txt" containing the robust tag SNPs for each block is
generated.
|
|
The program for
the iterative
LP-relaxation algorithm:
 |
The
iterative LP-relaxation algorithm is implemented in Perl, where the linear
programming is solved via a program called
lp_solve. To run this program,
you have to first install the Perl environment (http://www.activestate.com/).
|
 |
Download
(containing the Perl script ILPRelax.pl and the external
program lp_solve.exe).
|
 |
Input file
format: BlockID haplotype_frequence haplotype_pattern (see an
example). For the haplotype patterns,
we represent the major allele as 1, the minor allele as 0, and the missing
allele as n. The following is an input file of two haplotype blocks, each of
them contains 2 haplotype patterns with 7 SNPs.
 |
Block1 2
1100110
|
 |
Block1 1
1111n00
|
 |
Block2 4
1100101
|
 |
Block2 3
110010n
|
|
 |
This program
requires two input parameters.
 |
Parameter 1:
the number of missing SNPs allowed.
|
 |
Parameter 2:
the input file containing haplotype blocks.
|
|
 |
For example,
if you wanna tolerate 3 missing SNPs and the input file is test.dat. In the
command line, please type
 |
perl
ILPRelax.pl 3 test.dat
|
 |
An output
file "ILP_3.txt" containing the robust tag SNPs for each block is generated.
|
|
The program for
finding the optimum solution:
 |
The program
for finding the optimum solution is implemented in Java. To run this program, you have to
first download the Java Development Kit (JDK) from
http://java.sun.com. You can compile the
Java sources and then run the program.
|
 |
Source code:
including RunOPT.java and Optimize.java.
|
 |
Java classes:
you can skip the compiling process by running these classes directly.
|
 |
Input file
format: BlockID haplotype_frequence haplotype_pattern (see an
example). For the haplotype patterns,
we represent the major allele as 1, the minor allele as 0, and the missing
allele as n. The following is an input file of two haplotype blocks, each of
them contains 2 haplotype patterns with 7 SNPs.
 |
Block1 2
1100n10
|
 |
Block1 1
1n11000
|
 |
Block2 4
1100101
|
 |
Block2 3
1100101
|
|
 |
Running this program
requires two input parameters.
 |
Parameter 1:
the number of missing SNPs allowed.
|
 |
Parameter 2:
the input file containing haplotype blocks.
|
|
 |
For example,
if you wanna tolerate 3 missing SNPs and the input file is test.dat. In the
command line, please type
 |
java RunOPT 3 test.dat
|
 |
An output
file "OPT_3.txt" containing the robust tag SNPs for each block is
generated.
|
|
|