View Single Post
Old 08-08-2018, 10:11 PM   #4
Gopo
Member
 
Location: Louisiana

Join Date: Nov 2013
Posts: 38
Default

You will have to make the BED file yourself. Here is a guide:

Code:
# install picard
cd ~/bin/
wget https://github.com/broadinstitute/picard/releases/download/2.18.10/picard.jar
mv picard.jar picard-2.18.10.jar

# index reference (Reference is AmexG_v3.0.0.fa)
samtools faidx AmexG_v3.0.0.fa

# create sequence dictionary
java -Xmx64g -jar ~/bin/picard-2.18.10.jar CreateSequenceDictionary \
R=AmexG_v3.0.0.fa \
O=AmexG_v3.0.0.dict

# Convert BED to interval list
java -jar ~/bin/picard-2.18.10.jar BedToIntervalList \
I=rfs.immunome.bed \
O=rfs.immunome.interval.list \
SD=AmexG_v3.0.0.dict

# run CollectHsMetrics
java -Xmx64g -jar ~/bin/picard-2.18.10.jar CollectHsMetrics \
BAIT_INTERVALS=/ssdwork/jelber2/rfs/rfs.immunome.interval.list \
BAIT_SET_NAME=Immunome \
TARGET_INTERVALS=/ssdwork/jelber2/rfs/rfs.immunome.interval.list \
METRIC_ACCUMULATION_LEVEL=SAMPLE \
R=/ssdwork/jelber2/rfs/AmexG_v3.0.0.fa \
I=ALL-samples.bam \
O=ALL-samples-coverage-metrics.txt

# if needed, add readgroups
java -Xmx64g -jar ~/bin/picard.jar AddOrReplaceReadGroups \
I=ALL-samples.bam \
O=ALL-samples-RG.bam \
SORT_ORDER=coordinate \
RGPL=illumina \
RGPU=barcode \
RGLB=Lib1 \
RGID=all \
RGSM=all \
VALIDATION_STRINGENCY=LENIENT

# run CollectHsMetrics with ReadGroups added to BAM
java -Xmx64g -jar ~/bin/picard-2.18.10.jar CollectHsMetrics \
BAIT_INTERVALS=/ssdwork/jelber2/rfs/rfs.immunome.interval.list \
BAIT_SET_NAME=Immunome \
TARGET_INTERVALS=/ssdwork/jelber2/rfs/rfs.immunome.interval.list \
METRIC_ACCUMULATION_LEVEL=SAMPLE \
R=/ssdwork/jelber2/rfs/AmexG_v3.0.0.fa \
I=ALL-samples-RG.bam \
O=ALL-samples-coverage-metrics.txt
Best,
Gopo

Last edited by Gopo; 08-08-2018 at 10:12 PM. Reason: wrong syntax for displaying code
Gopo is offline   Reply With Quote