Skip to content

Instantly share code, notes, and snippets.

@vidboda
Last active April 6, 2018 15:01
Show Gist options
  • Save vidboda/b70c57c7dfe58d4abaed367574bd4f01 to your computer and use it in GitHub Desktop.
Save vidboda/b70c57c7dfe58d4abaed367574bd4f01 to your computer and use it in GitHub Desktop.
awk to convert bed file to position intervals file
BEGIN {OFS=""} {if ($1 !~ /track/) {print $1,":",$2+1,"-",$3}}
#one-liner:
#awk 'BEGIN {OFS=""} {if ($1 !~ /track/) {print $1,":",$2+1,"-",$3}}' file.bed > file.list
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment