-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathtrgtProcessing.sh
More file actions
29 lines (21 loc) · 797 Bytes
/
trgtProcessing.sh
File metadata and controls
29 lines (21 loc) · 797 Bytes
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
#!/bin/bash
# This shell script downloads and runs TRGT on the file given
# input1: path to input bam
# input2: prefix for naming this sample
# input3: path to reference genome
# input4: path to variant catalog
inputBam=$1
samplePrefix=$2
ref=$3
catalog=$4
# download TRGT
wget https://github.com/PacificBiosciences/trgt/releases/download/v0.3.3/trgt-v0.3.3-linux_x86_64.gz
gunzip trgt-v0.3.3-linux_x86_64.gz
mv trgt-v0.3.3-linux_x86_64 trgt
chmod 700 trgt
# prepare to run segmentation script
pip install pandas Levenshtein regex
# genotype tandem repeats with TRGT
./trgt --genome ${ref} --repeats ${catalog} --reads ${inputBam} --threads $(nproc) --output-prefix ${samplePrefix}
# parse TRGT output specifically for the FGF14 locus
python segmentTRGTAlleles.py --sample=${samplePrefix}