You are here
Biopython is a set of freely available tools for biological computation written in Python by an international team of developers.
To run this software in a Linux environment use the commands:
module load biopython biopython
Biopython has a number of modules that can be used in your Python scripts. Writing Python scripts is outside the scope of this document, but below is a small example of how to read and print sequence data from a file name test.fa:
#!/usr/bin/python from Bio import SeqIO for seq_record in SeqIO.parse("test.fa", "fasta"): print seq_record.id print repr(seq_record.seq) print len(seq_record)
You can also use Biopython from the Python shell and import modules as needed:
python >>> from Bio import SeqIO
More information, including documentation and tutorials, may be found at the the Biopython homepage.