4

I used

bioawk -cfastx 'length($seq) > 1 {print "@"$name"\n"$seq"\n+\n"$qual}' in.fq.qz | gzip > out.fq.qz

in order to keep a particular read length, but this command shortened the header from

@A00199:161:HF3JLDMXX:1:1101:5882:1063 2:N:0:CTGTAGCC+GAACAGGC

to

@A00199:161:HF3JLDMXX:1:1101:5882:1063

How is it possible to fix the bioawk command to remain the full command?

Devon Ryan
  • 19,602
  • 2
  • 29
  • 60
user977828
  • 453
  • 3
  • 9

1 Answers1

5
bioawk -cfastx 'length($seq) > 1 {print "@"$name $comment"\n"$seq"\n+\n"$qual}' in.fq.qz | gzip > out.fq.qz

Note the addition of $comment, which is what follows the name on the first line of each entry.

Devon Ryan
  • 19,602
  • 2
  • 29
  • 60