Performing basic sequence analysis
We will now do some basic analysis of DNA sequences. We will work with FASTA files and do some manipulation, such as reverse complementing or transcription. As with the previous recipe, we will use Biopython, which you installed in Chapter 1, Python and the Surrounding Software Ecology. These two recipes provide you with the necessary introductory building blocks with which we will perform all the modern NGS analysis and then genome processing in this chapter and Chapter 5, Working with Genomes.
Getting ready
The code for this recipe is available in Chapter03/Basic_Sequence_Processing.py
. We will use the human lactase (LCT) gene as an example; you can get this using your knowledge from the previous recipe, by using the Entrez
research interface:
from Bio import Entrez, SeqIO, SeqRecord Entrez.email = "[email protected]" hdl = Entrez.efetch(db='nucleotide', id=['NM_002299'], rettype='gb') # Lactase gene...