Delete line if next line starts with pattern
You could try something like this:
$ sed -e '$!N;/^>.*\n>/D' -e 'P;D' file
>seq1
actgatgac
>seq2
ctgacgtca
>seq4
gtagctagt
>seq5
tgacatgca
That is
- maintain a two line buffer with
$!N
...P;D
- look for a pattern that starts with
>
and has another>
after the newline - delete up to the newline