Hi,
How to count aminoacids from a text file ? My file contains 1200 sequences. After getting amino acid composition, I have to create a Bar plot. How to do these things in Bio python?
I parsed the sequence file in to Biopython. I tried the following code to get amino acid composition. I have to get the composition for each sequence. But I got the composition only for the first sequence.
from Bio.SeqUtils.ProtParam import ProteinAnalysis
x = ProteinAnalysis("cc.fasta") // cc.fasta is my sequence file.I have already parsed this to biopython.
print x.count_amino_acids()
Please help to solve this problem.
The Biopython tutorial is a great place to get started; specifically the section on parsing sequences: http://biopython.org/DIST/docs/tutorial/Tutorial.html#htoc47 For plotting, matplotlib is a popular choice: http://matplotlib.sourceforge.net/