Skip to content

Instantly share code, notes, and snippets.

@antonkulaga
Last active August 29, 2015 14:18
Show Gist options
  • Save antonkulaga/fdbd6a1ef43a0f188c55 to your computer and use it in GitHub Desktop.
Save antonkulaga/fdbd6a1ef43a0f188c55 to your computer and use it in GitHub Desktop.
transcriptome assembly with Scythe-Sickle-Bowtie-Tophat-Stringtie-Cuffdiff
#NOTE: all actions are done with three samples, that have names: 3,4 and 9
###IMPROVING FASTQ###
#deleting illumina adapters by https://github.com/vsbuffalo/scythe
./sickle se -f /home/uploader/flies/assembly5/3_cleaned.fastq -t sanger /home/uploader/flies/assembly5/3.fastq
./sickle se -f /home/uploader/flies/assembly5/4_cleaned.fastq -t sanger /home/uploader/flies/assembly5/4.fastq
./sickle se -f /home/uploader/flies/assembly5/9_cleaned.fastq -t sanger /home/uploader/flies/assembly5/9.fastq
#triming fastq by https://github.com/najoshi/sickle
sickle se -f /home/uploader/flies/assembly5/3_cleaned.fastq -t sanger -o /home/uploader/flies/assembly5/3.fastq -q 25
sickle se -f /home/uploader/flies/assembly5/4_cleaned.fastq -t sanger -o /home/uploader/flies/assembly5/4.fastq -q 25
sickle se -f /home/uploader/flies/assembly5/9_cleaned.fastq -t sanger -o /home/uploader/flies/assembly5/9.fastq -q 25
###Building Bowtie2 index###
bowtie2-build dmel-all-chromosome-r6.04.fasta genome
###Building Tophat2 transcriptome index###
tophat2 -p 6 --GTF dmel.gtf --transcriptome-index transcriptome genome
###Tophat2 Alignment
#sample called 3
tophat2 -p 6 --GTF dmel.gtf --transcriptome-index transcriptome -o 3.tophat genome 3.fastq
#sample called 4
tophat2 -p 6 --GTF dmel.gtf --transcriptome-index transcriptome -o 4.tophat genome 4.fastq
#sample called 9
tophat2 -p 6 --GTF dmel.gtf --transcriptome-index transcriptome -o 9.tophat genome 9.fastq
###SamTools###
samtools view -h 3_tophat/accepted_hits.bam > 3_tophat/accepted_hits.sam
samtools view -h 4_tophat/accepted_hits.bam > 4_tophat/accepted_hits.sam
samtools view -h 9_tophat/accepted_hits.bam > 9_tophat/accepted_hits.sam
###Stringtie mapping###
stringtie 3_tophat/accepted_hits.bam -G dmel.gtf -o 3.gtf -v -m 100
stringtie 4_tophat/accepted_hits.bam -G dmel.gtf -o 4.gtf -v -m 100
stringtie 9_tophat/accepted_hits.bam -G dmel.gtf -o 9.gtf -v -m 100
###Merging###
cuffmerge -o /home/uploader/flies/assembly5 -g /home/uploader/flies/assembly5/dmel.gtf -s /home/uploader/flies/assembly5/genome.fa -p 4 /home/uploader/flies/assembly5/merge.txt
#In file we say:
#/home/uploader/flies/assembly5/3.gtf
#/home/uploader/flies/assembly5/4.gtf
#/home/uploader/flies/assembly5/9.gtf
###Quantification###
cuffquant -p 4 -o 3_cuffquant merged.gtf 3_tophat/accepted_hits.bam
cuffquant -p 4 -o 4_cuffquant merged.gtf 4_tophat/accepted_hits.bam
cuffquant -p 4 -o 9_cuffquant merged.gtf 9_tophat/accepted_hits.bam
###Differential expressions analysis###
cuffdiff -p 4 -o geometric_norm.cuffdiff merged.gtf 3_cuffquant/abundances.cxb 4_cuffquant/abundances.cxb 9_cuffquant/abundances.cxb -b /home/uploader/flies/assembly5/genome.fa
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment