-
Notifications
You must be signed in to change notification settings - Fork 2
/
Copy pathrun_dREG-HD.bsh
executable file
·40 lines (33 loc) · 1.09 KB
/
run_dREG-HD.bsh
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
#!/bin/bash
if [ "$#" -lt 5 ]; then
echo ""
echo "USAGE: bash run_dREG-HD.bsh dREG_bed plus_strand.bw minus_strand.bw HD_model.rdata [nthreads] [GPU]"
echo ""
echo "dREG_bed -- the dREG peaks in bed format."
echo "plus_strand.bw -- PRO-seq data (plus strand) formatted as a bigWig file."
echo "minus_strand.bw -- PRO-seq data (minus strand) formatted as a bigWig file."
echo "HD_model.rdata -- The path to the RData file containing the pre-trained dREG-HD SVM model."
echo "[nthreads] -- [optional, default=1] The number of threads to use when evaluating dREG-HD sites."
echo "[GPU] -- [optional, gpu or blank, default is blank] indicating whether GPU package can be used."
echo ""
exit 1
fi
pushd `dirname $0` > /dev/null
bsh_path=`pwd`
popd > /dev/null
bed=$1
bwPL=$2
bwMN=$3
model=$4
gpu=FALSE
ncores=1
if [ "$#" -gt 4 ]; then
ncores=$5
else
ncores=1
fi
if [ "$#" -gt 5 ]; then
gpu=$6
fi
echo "Using: R --vanilla --slave --args $bed $bwPL $bwMN $model $ncores $gpu < $bsh_path/run_dREG-HD.R"
R --vanilla --slave --args $bed $bwPL $bwMN $model $ncores $gpu < $bsh_path/run_dREG-HD.R