Entering edit mode
5.4 years ago
fec2
▴
50
Hi,
I have a FASTA file and need to split the file into multiple FASTAs, one gene per file. Refer to the post Splitting A Fasta File, I have tried below
awk -F "|" '/^>/ {close(F) ; F = $1".fasta"} {print >> F}' yourfile.fa
However, every output file name contain symbol ">", for example ">my_contig_name.fasta".
May I know how to avoid to have ">" in the output file name? Thanks.
Please use the search function, this has been asked many times before:
Split multifasta file in individual sequence file
How to split a multi fasta file into individual chromosomes
splitting multifasta-file in python
Split the multiple sequences file into a separate files
Hi,
Actually I have tried several command from these posts, but only the above command work for me. However, this command has created ">" in the output name.