This is a test version of Biostars. For the public version, visit https://www.biostars.org.
How To Split Fasta File In Python

how to split sequences in fasta file to sup-groups, each sub group contain nine sequences, then , I apply some function on each sub-group

split fasta python

looks like a homework ; What have you tried ?

ok, to extract sequences from fasta file :

 outfile=open('file.txt', 'w')
for line in open('sequences.fasta'):
    if line[0]==">":
        outfile.write('\n')
    else:
        outfile.write(line.strip())

0 answers

No answers yet.

Log in to answer this question.