1:下载knownGene.txt.gz:
ftp://hgdownload.soe.ucsc.edu/goldenPath/hg19/database/knownGene.txt.gz
2:下载genePredToGtf:http://hgdownload.soe.ucsc.edu/admin/exe/linux.x86_64/genePredToGtf
3:gzip -d refGene.txt.gz
4:cut -f 2- refGene.txt > refGene.input
5:genePredToGtf file refGene.input hg19refGene.gtf
6:cat hg19refGene.gtf | sort -k1,1 -k4,4n > hg19refGene.gtf.sorted
参考链接:http://genomewiki.ucsc.edu/index.php/Genes_in_gtf_or_gff_format