Skip to content

Commit b70b743

Browse files
author
Schon
committed
bugfix: pointer errors to reference files in endMask.sh
1 parent 81a986f commit b70b743

File tree

1 file changed

+6
-29
lines changed

1 file changed

+6
-29
lines changed

endMask.sh

Lines changed: 6 additions & 29 deletions
Original file line numberDiff line numberDiff line change
@@ -92,7 +92,7 @@ then
9292
fi
9393
if [ -z "$transcript_fasta" ]
9494
then
95-
transcript_fasta=$resource_dir/transcript.fasta
95+
transcript_fasta=$resource_dir/transcriptome.fasta
9696
fi
9797
if [ -z "$LMOD" ]
9898
then
@@ -111,22 +111,9 @@ then
111111
output_folder=$results_dir/EndMask
112112
fi
113113

114-
############################
115-
# READING THE COMMAND LINE #
116-
############################
117-
# Taking the default variables above, modifying them with the commandline
118-
# arguments (see read_cmdline.sh), and writing a config file
119-
120-
. $bash_dir/read_cmdline.sh
121-
122-
echo "###############"
123-
echo "### ENDMASK ###"
124-
echo "###############"
125-
echo " "
126114
echo "Config settings:"
127115
. $bash_dir/list_settings.sh
128116

129-
130117
# Environment modules to load with Lmod (if option --lmod is passed)
131118
REQUIRED_MODULES=( --bedtools )
132119
. $bash_dir/load_modules.sh
@@ -153,16 +140,14 @@ samples=( $(echo "${picked_from_table[@]}" | tr [:blank:] \\n | sort -u) )
153140
length_table=$resource_dir/length.table
154141
mask=$python_dir/bedgraph_mask.py
155142
coverage=$python_dir/bed_feature_coverage.py
156-
output_folder=$results_dir/EndMask
157-
data_folder=$output_folder/$SAMPLE_NAME
143+
data_folder=$output_folder/$SAMPLE_TYPE
158144

159145
rm -rf $data_folder
160146
mkdir -p $data_folder
161147
cd $data_folder
162148

163-
samples=($sample_list)
164149
echo "Samples: ${samples[@]}"
165-
echo "Sample type: $SAMPLE_NAME"
150+
echo "Sample type: $SAMPLE_TYPE"
166151

167152
###########################
168153
# CALCULATE READ COVERAGE #
@@ -186,7 +171,6 @@ python $python_dir/bedgraph_dominant_transcripts.py \
186171
rm $SAMPLE_NAME.all.transcript.bedgraph $SAMPLE_NAME.dom.transcript.bedgraph
187172

188173
echo "Making gene-level bed files..."
189-
bedgraph_list=()
190174
for s in ${samples[@]}
191175
do
192176
# Perform cap masking on all 5' end bedgraphs (genome level)
@@ -206,15 +190,8 @@ do
206190
--output $s.transcript.capmasked.bedgraph \
207191
$data_folder/$s.capmask.plus.bedgraph \
208192
$data_folder/$s.capmask.minus.bedgraph \
209-
$annotation_gff \
210-
$genome_fasta
193+
$ANNOTATION_GFF \
194+
$GENOME_FASTA
211195

212-
# Remove intermediate files
213-
rm $s.transcript.capmasked.bedgraph
214-
bedgraph_list+=( $s.transcript.bedgraph )
215196
done
216-
python $python_dir/bedgraph_combine.py \
217-
-i ${bedgraph_list[@]} \
218-
-o $SAMPLE_NAME.transcript.bedgraph
219-
220-
197+
echo "EndMask complete! See results in results/EndMask/$SAMPLE_TYPE"

0 commit comments

Comments
 (0)