annotate igblast/igblast.sh @ 16:21ca9391a3b7 draft

Uploaded
author davidvanzessen
date Tue, 20 Dec 2016 09:06:51 -0500
parents 8cbc1a8d27ae
children 4d2a8f98a502
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
0
afe85eb6572e Uploaded
davidvanzessen
parents:
diff changeset
1 set -e
afe85eb6572e Uploaded
davidvanzessen
parents:
diff changeset
2
afe85eb6572e Uploaded
davidvanzessen
parents:
diff changeset
3 dir="$(cd "$(dirname "$0")" && pwd)"
afe85eb6572e Uploaded
davidvanzessen
parents:
diff changeset
4
afe85eb6572e Uploaded
davidvanzessen
parents:
diff changeset
5 input=$1
afe85eb6572e Uploaded
davidvanzessen
parents:
diff changeset
6 species=$2
afe85eb6572e Uploaded
davidvanzessen
parents:
diff changeset
7 locus=$3
afe85eb6572e Uploaded
davidvanzessen
parents:
diff changeset
8 output=$4
afe85eb6572e Uploaded
davidvanzessen
parents:
diff changeset
9
6
d001d0c05dbe Uploaded
davidvanzessen
parents: 0
diff changeset
10 declare -A speciesdict
d001d0c05dbe Uploaded
davidvanzessen
parents: 0
diff changeset
11
7
54f6756bacb1 Uploaded
davidvanzessen
parents: 6
diff changeset
12 speciesdict=(["Rattus norvegicus functional"]="rat" ["Rattus norvegicus non-functional"]="rat" ["Oryctolagus cuniculus functional"]="rabbit" ["Oryctolagus cuniculus non-functional"]="rabbit" ["Mus musculus functional"]="mouse" ["Mus musculus non-functional"]="mouse" ["Homo sapiens functional"]="human" ["Homo sapiens non-functional"]="human" ["Macaca mulatta non-functional"]="rhesus_monkey" ["Macaca mulatta functional"]="rhesus_monkey")
54f6756bacb1 Uploaded
davidvanzessen
parents: 6
diff changeset
13
54f6756bacb1 Uploaded
davidvanzessen
parents: 6
diff changeset
14 echo "Species: $species ${speciesdict[$species]}"
54f6756bacb1 Uploaded
davidvanzessen
parents: 6
diff changeset
15
54f6756bacb1 Uploaded
davidvanzessen
parents: 6
diff changeset
16 species="${speciesdict[$species]}"
0
afe85eb6572e Uploaded
davidvanzessen
parents:
diff changeset
17
8
8cbc1a8d27ae Uploaded
davidvanzessen
parents: 7
diff changeset
18 if [ "$species" == "" ]
8cbc1a8d27ae Uploaded
davidvanzessen
parents: 7
diff changeset
19 then
8cbc1a8d27ae Uploaded
davidvanzessen
parents: 7
diff changeset
20 >&2 echo "Species not possible with igBLASTn, use IMGT"
8cbc1a8d27ae Uploaded
davidvanzessen
parents: 7
diff changeset
21 exit 1
8cbc1a8d27ae Uploaded
davidvanzessen
parents: 7
diff changeset
22 fi
8cbc1a8d27ae Uploaded
davidvanzessen
parents: 7
diff changeset
23
0
afe85eb6572e Uploaded
davidvanzessen
parents:
diff changeset
24 echo "$input $species $locus $output"
afe85eb6572e Uploaded
davidvanzessen
parents:
diff changeset
25
8
8cbc1a8d27ae Uploaded
davidvanzessen
parents: 7
diff changeset
26 java -Xmx16G -jar $IGBLASTWRP/igblastwrp.jar -p 4 -S $species -R $locus ${input} $PWD/blasted_output 2>&1
7
54f6756bacb1 Uploaded
davidvanzessen
parents: 6
diff changeset
27 #java -Xmx64G -jar $dir/igblastwrp.jar -p 4 -S $species -R $locus ${input} $PWD/blasted_output 2>&1
54f6756bacb1 Uploaded
davidvanzessen
parents: 6
diff changeset
28 #java -Xmx64G -jar $dir/migmap-1.0.1.jar -p 4 -S "$species" -R $locus ${input} $PWD/blasted_output 2>&1
0
afe85eb6572e Uploaded
davidvanzessen
parents:
diff changeset
29
afe85eb6572e Uploaded
davidvanzessen
parents:
diff changeset
30 Rscript --verbose $dir/igblast.r "$PWD/blasted_output.L2.txt" "$output" 2>&1