annotate admixture.sh @ 7:c3ebf600f975 draft default tip

planemo upload
author dereeper
date Wed, 13 Apr 2016 08:07:24 -0400
parents 97c9c8daa3c3
children
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
4
58df6910f1c3 planemo upload
dereeper
parents:
diff changeset
1 #!/bin/bash
58df6910f1c3 planemo upload
dereeper
parents:
diff changeset
2 bed=$1
58df6910f1c3 planemo upload
dereeper
parents:
diff changeset
3 fam=$2
58df6910f1c3 planemo upload
dereeper
parents:
diff changeset
4 bim=$3
58df6910f1c3 planemo upload
dereeper
parents:
diff changeset
5 outputs=$4
58df6910f1c3 planemo upload
dereeper
parents:
diff changeset
6 logs=$5
58df6910f1c3 planemo upload
dereeper
parents:
diff changeset
7 best_k_output=$6
58df6910f1c3 planemo upload
dereeper
parents:
diff changeset
8 best_k_logfile=$7
58df6910f1c3 planemo upload
dereeper
parents:
diff changeset
9 kmin=$8
58df6910f1c3 planemo upload
dereeper
parents:
diff changeset
10 kmax=$9
5
97c9c8daa3c3 planemo upload
dereeper
parents: 4
diff changeset
11 groups=${10}
97c9c8daa3c3 planemo upload
dereeper
parents: 4
diff changeset
12 threshold_group=${11}
4
58df6910f1c3 planemo upload
dereeper
parents:
diff changeset
13
58df6910f1c3 planemo upload
dereeper
parents:
diff changeset
14 directory=`dirname $0`
58df6910f1c3 planemo upload
dereeper
parents:
diff changeset
15 mkdir tmpdir$$
58df6910f1c3 planemo upload
dereeper
parents:
diff changeset
16 cp -rf $bed tmpdir$$/input.bed
58df6910f1c3 planemo upload
dereeper
parents:
diff changeset
17 cp -rf $fam tmpdir$$/input.fam
58df6910f1c3 planemo upload
dereeper
parents:
diff changeset
18 cp -rf $bim tmpdir$$/input.bim
58df6910f1c3 planemo upload
dereeper
parents:
diff changeset
19
58df6910f1c3 planemo upload
dereeper
parents:
diff changeset
20
5
97c9c8daa3c3 planemo upload
dereeper
parents: 4
diff changeset
21 perl $directory/Admixture.pl -i tmpdir$$/input -o $outputs -k $kmin -m $kmax -d tmpdir$$ -t $threshold_group
4
58df6910f1c3 planemo upload
dereeper
parents:
diff changeset
22
58df6910f1c3 planemo upload
dereeper
parents:
diff changeset
23 mv tmpdir$$/output $best_k_output
58df6910f1c3 planemo upload
dereeper
parents:
diff changeset
24 mv tmpdir$$/log $best_k_logfile
58df6910f1c3 planemo upload
dereeper
parents:
diff changeset
25 mv tmpdir$$/outputs.Q $outputs
58df6910f1c3 planemo upload
dereeper
parents:
diff changeset
26 mv tmpdir$$/logs $logs
5
97c9c8daa3c3 planemo upload
dereeper
parents: 4
diff changeset
27 mv tmpdir$$/groups $groups
4
58df6910f1c3 planemo upload
dereeper
parents:
diff changeset
28
58df6910f1c3 planemo upload
dereeper
parents:
diff changeset
29