Skip to content

Instantly share code, notes, and snippets.

@opplatek
Created December 30, 2021 20:19
Show Gist options
  • Save opplatek/cc3815bd462d5e73eec2c0ccc6393b6d to your computer and use it in GitHub Desktop.
Save opplatek/cc3815bd462d5e73eec2c0ccc6393b6d to your computer and use it in GitHub Desktop.
Extract fastq sequence or names
# Get all the sequences from fastq.gz
zcat in.fastq.gz | awk 'NR == 2 || NR % 4 == 2'
# Get all the sequence names from fastq.gz
zcat in.fastq.gz | awk 'NR == 1 || NR % 4 == 1'
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment