extract sequences from a fasta file and save into different files
3
1
Entering edit mode
6.6 years ago
Eva_Maria ▴ 190

Hey I have a fasta file which contains more than 80 sequences. I want to take each sequences in different files and the file name should be header of corresponding sequence.

perl sequence awk fasta • 2.6k views
ADD COMMENT
0
Entering edit mode

That's simple but the header should not contain illegal characters for a filename i.e. \ / : * ? " < > |

a simple loop will do that if one takes care of these chars.

ADD REPLY
0
Entering edit mode

yup header like this only GCF_000196095n.fasta_2 ..

ADD REPLY
0
Entering edit mode

duplicate of : Splitting A Fasta File

ADD REPLY
3
Entering edit mode
6.6 years ago
$ pip install pyfaidx
$ faidx --split-files in.fasta
ADD COMMENT
2
Entering edit mode
ADD COMMENT
1
Entering edit mode
ADD COMMENT
0
Entering edit mode

thank u sir... its working

ADD REPLY

Login before adding your answer.

Traffic: 1020 users visited in the last hour
Help About
FAQ
Access RSS
API
Stats

Use of this site constitutes acceptance of our User Agreement and Privacy Policy.

Powered by the version 2.3.6