Skip to content

Commit d032b06

Browse files
committed
update ensembl hg19
1 parent 813b6b9 commit d032b06

File tree

1 file changed

+15
-20
lines changed

1 file changed

+15
-20
lines changed

Makefile

Lines changed: 15 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -5,12 +5,12 @@
55
none:
66

77
# make all sets of annotations
8-
all: gencode ensembl gencode-hg38 ensembl-hg38
8+
all: gencode-hg19 ensembl-hg19 gencode-hg38 ensembl-hg38
99

1010

1111
# ~~~~~ GENCODE hg19 ~~~~~ #
1212
# generate the Gencode hg19 annotations .bed file
13-
gencode: gencode.v19.annotation.genes.bed
13+
gencode-hg19: gencode.v19.annotation.genes.bed
1414

1515
gencode.v19.annotation.gtf.gz:
1616
wget ftp://ftp.sanger.ac.uk/pub/gencode/Gencode_human/release_19/gencode.v19.annotation.gtf.gz
@@ -36,27 +36,20 @@ gencode.v27.annotation.genes.bed: gencode.v27.annotation.gtf.gz
3636

3737
# ~~~~~ ENSEMBL hg19 ~~~~~ #
3838
# generate the Ensembl hg19 annotations .bed file
39-
ensembl: Homo_sapiens.GRCh37.82.noGLMT.chr.genes.bed
39+
ensembl-hg19: Homo_sapiens.GRCh37.82.chr.bed
4040

41-
Homo_sapiens.GRCh37.82.gtf.gz:
42-
wget ftp://ftp.ensembl.org/pub/grch37/release-84/gtf/homo_sapiens/Homo_sapiens.GRCh37.82.gtf.gz
41+
Homo_sapiens.GRCh37.82.chr.gtf.gz:
42+
wget ftp://ftp.ensembl.org/pub/grch37/release-84/gtf/homo_sapiens/Homo_sapiens.GRCh37.82.chr.gtf.gz
4343

44-
# Need to filter out the GL, MT entries
45-
Homo_sapiens.GRCh37.82.noGLMT.gtf: Homo_sapiens.GRCh37.82.gtf.gz
46-
zcat Homo_sapiens.GRCh37.82.gtf.gz | grep -Ev "^#|^GL|^M" > Homo_sapiens.GRCh37.82.noGLMT.gtf
47-
48-
# need to add 'chr' to the start of each 1st entry
49-
Homo_sapiens.GRCh37.82.noGLMT.chr.gtf: Homo_sapiens.GRCh37.82.noGLMT.gtf
50-
cat Homo_sapiens.GRCh37.82.noGLMT.gtf | sed 's/^/chr/' > Homo_sapiens.GRCh37.82.noGLMT.chr.gtf
44+
# remove comment lines
45+
# extract only 'gene' entries
46+
# add 'chr' to first entry, change 'chrMT' to 'chrM'
47+
Homo_sapiens.GRCh37.82.chr.gtf: Homo_sapiens.GRCh37.82.chr.gtf.gz
48+
zcat Homo_sapiens.GRCh37.82.chr.gtf.gz | grep -Ev '^#' | grep -w 'gene' | sed -e 's/^/chr/' -e 's/^chrMT/chrM/' > Homo_sapiens.GRCh37.82.chr.gtf
5149

5250
# convert to .bed
53-
Homo_sapiens.GRCh37.82.noGLMT.chr.bed: Homo_sapiens.GRCh37.82.noGLMT.chr.gtf
54-
gtf2bed < Homo_sapiens.GRCh37.82.noGLMT.chr.gtf > Homo_sapiens.GRCh37.82.noGLMT.chr.bed
55-
56-
# extract genes
57-
Homo_sapiens.GRCh37.82.noGLMT.chr.genes.bed: Homo_sapiens.GRCh37.82.noGLMT.chr.bed
58-
grep -w gene Homo_sapiens.GRCh37.82.noGLMT.chr.bed > Homo_sapiens.GRCh37.82.noGLMT.chr.genes.bed
59-
51+
Homo_sapiens.GRCh37.82.chr.bed: Homo_sapiens.GRCh37.82.chr.gtf
52+
gtf2bed < Homo_sapiens.GRCh37.82.chr.gtf > Homo_sapiens.GRCh37.82.chr.bed
6053

6154

6255

@@ -86,6 +79,8 @@ Homo_sapiens.GRCh38.91.chr.bed: Homo_sapiens.GRCh38.91.chr.gtf
8679
Homo_sapiens.GRCh37.82.noGLMT.chr.gtf \
8780
gencode.v27.annotation.gtf.gz \
8881
Homo_sapiens.GRCh38.91.chr.gtf \
89-
Homo_sapiens.GRCh38.91.chr.gtf.gz
82+
Homo_sapiens.GRCh38.91.chr.gtf.gz \
83+
Homo_sapiens.GRCh37.82.chr.gtf \
84+
Homo_sapiens.GRCh37.82.chr.gtf.gz
9085

9186

0 commit comments

Comments
 (0)