Commit 22296bd9 authored by Gonzalo S Nido's avatar Gonzalo S Nido
Browse files

Fixed Lambda chromosome name and added test

parent aac44737
......@@ -2,7 +2,7 @@
# Some variables
MT_chr_name="chrM"
LAMBDA_chr_name="chrL"
LAMBDA_chr_name="NC_001416.1"
# Get pipeline folder
PIPELINEPATH="$( cd "$(dirname "$0")" > /dev/null 2>&1 ; pwd -P )"
......@@ -43,7 +43,25 @@ SUBSET_READS=false
########################################
# Check that both MT chromosome and lambda are present in the reference
if ! grep -m1 -q "^>${MT_chr_name}" ${b38_ref}/Bisulfite_Genome/CT_conversion/genome_mfa.CT_conversion.fa; then
echo "ERROR: \"${MT_chr_name}\" does not exist in ${b38_ref}"
exit 1
fi
if grep -m1 -q "^>${MT_chr_name}" ${nuc_ref}/Bisulfite_Genome/CT_conversion/genome_mfa.CT_conversion.fa; then
echo "ERROR: \"${MT_chr_name}\" is present in the nuclear-only reference: ${nuc_ref}"
exit 1
fi
if ! grep -m1 -q "^>${MT_chr_name}" ${mt_ref}/Bisulfite_Genome/CT_conversion/genome_mfa.CT_conversion.fa; then
echo "ERROR: \"${MT_chr_name}\" does not exist in ${mt_ref}"
exit 1
fi
if ! grep -m1 -q "^>${LAMBDA_chr_name}" ${b38_ref}/Bisulfite_Genome/CT_conversion/genome_mfa.CT_conversion.fa; then
echo "ERROR: \"${LAMBDA_chr_name}\" does not exist in ${b38_ref}"
exit 1
fi
exit 2
# Exit when any command fails
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment