https://github.com/arjunrajlaboratory/RajLabSeqTools
Revision 3ad90f05fa0acafab6fafac654b71d266e5953d7 authored by Sydney Shaffer on 24 November 2015, 20:55:21 UTC, committed by Sydney Shaffer on 24 November 2015, 20:55:21 UTC
1 parent a01431b
Tip revision: 3ad90f05fa0acafab6fafac654b71d266e5953d7 authored by Sydney Shaffer on 24 November 2015, 20:55:21 UTC
Changed folder names and the appropriate files to make things a bit clearer in the ATAC analysis. Specifically, the stepThreeHOMERpeaks folder was renamed to stepFourHOMERpeaks.
Changed folder names and the appropriate files to make things a bit clearer in the ATAC analysis. Specifically, the stepThreeHOMERpeaks folder was renamed to stepFourHOMERpeaks.
Tip revision: 3ad90f0
unzipAndConcatenateZippedFastq.sh
#!/bin/bash
ZIPFILEDIRECTORY=$1
OUTFASTADIRECTORY=$2
for dirname in $ZIPFIELDIRECTORY/* ; do
cd $dirname
INPUT=`ls *001_R1*`
SAMPLE=${INPUT%%_*} # Cuts filename string after first '_'
if [ ! -d $OUTFASTADIRECTORY/raw ]; then
mkdir $OUTFASTADIRECTORY/raw
fi
if [ ! -d $OUTFASTADIRECTORY/raw/$SAMPLE ]; then
mkdir $OUTFASTADIRECTORY/raw/$SAMPLE
fi
for i in *.gz; do
gunzip -c $i > ${i%.*}
done
FASTQR1=${SAMPLE}_R1.fastq
FASTQR2=${SAMPLE}_R2.fastq
cat *R1*fastq > $OUTFASTADIRECTORY/raw/$SAMPLE/$FASTQR1
cat *R2*fastq > $OUTFASTADIRECTORY/raw/$SAMPLE/$FASTQR2
done
Computing file changes ...