Repository navigation
Unix IV: NGS data quality
Course: HT17 Unix with applications to next generation sequencing data (SC00025)
In this exercise, we are going to inspect some NGS raw data to determine if the data is of good quality
Copy Fly_R1.fastq.gz and Fly_2.fastq.gz from /home/marcela/unix/files
Have a look at the files.
As a quick reminder, fastq files look like this (a more thorough description here). https://github.com/bcfgothenburg/HT17/wiki/Unix-IV:-NGS-data-quality @ERR030882.1 HWI-BRUNOP16X_0001:3:1:3055:1085#0/1 NNTCAAGTTTCCGTTTTAAACACCTCTTCCTGTGTGGCTCGCTTGTTTTC + ##(('(((''1,-.-33348FFFFFFFFFF,8/1/77777FFFFFFFF<<
Q1. How many sequences are there in Read1 and Read2?
Let's look at the quality.
Remember that the fourth row indicates the quality of the sequence read.
# indicates a low nucleotide quality (=2).
Q2. How many sequences are there where all the nucleotides in a read are #? In other words, how many sequences we will be discarding because we can not trust that sequence due to its really low quality?
If we say that sequences with more than 20 consecutive #'s are bad quality reads,
Q3. Which is the percentage of bad quality reads, for Read1 and Read2?
To inspect the overall quality of the sequences, we will use FastQC, which is already installed in the server. To know how to use the tool run:
fastqc -h
Once you have run the program, open the html reports and have a quick look:
firefox name_of_the_file.html &
Now filter the sequences with fastq_quality_filter, a program from the
FASTX-Toolkit. Again, use fastq_quality_filter -h to known how to run the tool. Use the following settings:
* Minimum quality score to keep: 30
* Minimum percent of bases that must have 30 qualtiy: 80
* -Q 33
Q4. How many reads do you have now?
Run fastQC on the filtered files and compare their quality to the quality of the raw files.
Q5. What do you think about the quality of the data?
Previous: Unix III: Warm up exercises
Created by Marcela Dávila