File: with-example-data

package info (click to toggle)
tabix 0.2.6-2
  • links: PTS, VCS
  • area: main
  • in suites: jessie, jessie-kfreebsd
  • size: 384 kB
  • ctags: 521
  • sloc: ansic: 3,759; java: 309; python: 126; perl: 91; makefile: 53; sh: 8
file content (26 lines) | stat: -rwxr-xr-x 658 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
#!/bin/sh -e

# Create a temporary file
TABIXDATA=$(mktemp)

# Uncompress example data
zcat /usr/share/doc/tabix/examples/example.gtf.gz > $TABIXDATA

# Compress example data with bgzip
bgzip $TABIXDATA

# Index with tabix
tabix -p gff $TABIXDATA.gz

# Extract with tabix the he features on chromosome 1 whose coordinates overlap
# the interval 150,309–150,309.
tabix $TABIXDATA.gz chr1:150309-150309 > $TABIXDATA.out

# Reference result at the bottom of this file
grep H\AVANA /usr/share/doc/tabix/README.test > $TABIXDATA.ref

# No difference ?
diff $TABIXDATA.ref $TABIXDATA.out

# Clean
rm $TABIXDATA.gz $TABIXDATA.gz.tbi $TABIXDATA.out $TABIXDATA.ref