This is a test version of Biostars. For the public version, visit https://www.biostars.org.
script to filter contigs >1kb

Hi

I have been looking for a script that could filter out the contigs which are >1kb. my assembled file has the following stats. could some one help me with the script to get contigs >1kb. I have been through all the post for the similar script but couldn't find a right one. thanks in advance.

Contig statistics:
Total length:    49295072 (n:27000)
Max:    788230
N20:    149300 (n:40)
N50:    57668 (n:200)
N80:    10314 (n:808)
n > 1kb:    2485
Tot bp in contigs > 1kb:    45136108 (91.563124%)
genome assembly

Another option, using the BBMap package:

reformat.sh in=contigs.fasta out=filtered.fasta minlength=1000

It's very fast. Also supports maxlength.

1 answer

Maybe this post can solve your issue.

Thanks !

That really helped. perfect!

You're welcome :)

Log in to answer this question.