I have a fasta file like this:
How do I remove all the sequences with a XR header?
I only want to keep:
If you do it on linux，it will be easy.
PS: Seqtk is a software that you need to install.
try with gnu-sed on ubuntu/mint:
$ sed -e '/^>XR/,+1d' test.fa
If you have multiline fasta, use seqkit:
$ seqkit grep -rvip "^XR" test.fa
You can try SEDA (https://www.sing-group.org/seda/). The Pattern filtering operation (https://www.sing-group.org/seda/manual/operations.html#pattern-filtering) would allow you to do this if you configure a Not contains pattern with the "^XR_" text.
Login before adding your answer.
Use of this site constitutes acceptance of our User Agreement and Privacy