A Python project I made to analyze DNA sequences. I'm doing A-levels (Bio, Chem, Physics) and started learning Python on the side. Wanted to build something that actually connects to what I study so this made sense.
It basically takes a DNA sequence and walks it through transcription and translation, plus a few other things.
- validates the input (only A T G C)
- GC content percentage
- complementary strand and reverse complement
- transcription (DNA to mRNA)
- translation (mRNA to protein) using the full codon table
- bar chart of nucleotide frequencies
- can read FASTA files from NCBI
pip install matplotlib
python dna_analyzer.py
three options come up:
- test it on a human insulin gene sequence I pulled from NCBI
- paste in your own sequence
- give it a FASTA file path
run option 1 to see it working straight away
dna_analyzer.py- main scriptcodon_table.py- all 64 codonssample_sequences/example.fasta- insulin, BRCA1, HIV-1 gag sequencesrequirements.txt
- ORF finder for all 6 reading frames
- fetch sequences from NCBI directly instead of downloading manually
- melting temperature for primers
- argparse so you can pass the sequence as a command line argument