Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR SHELL

bash read length of fasta file seqeunces

awk '/^>/ {if (seqlen){print seqlen}; print ;seqlen=0;next; } { seqlen += length($0)}END{print seqlen}' file.fa
Source by stackoverflow.com #
 
PREVIOUS NEXT
Tagged: #bash #read #length #fasta #file #seqeunces
ADD COMMENT
Topic
Name
2+6 =