Where do we suppose to mention the version of the genome reference hg19/hg38 etc?
Hi!
I am curious to know, how can I find all the genes within a genomic region, preferable in a file or may be in a separate window.
for instance say, I have a genomic region spanning from chr1:1,783,590-2,597,819 and I want to get all the genes present in this region how can I get it? I know I can use UCSC browser to see all the genes present in that region but how can I get it as a list in a file.
Thank you
2 answers
Or you can create a query in BioMart. Below an example using the Bioconductor biomaRt package (a wrapper to the on-line web service):
library(biomaRt)
mart <- useMart("ensembl")
mart <- useDataset("hsapiens_gene_ensembl", mart)
attributes <- c("ensembl_gene_id","start_position","end_position","strand","hgnc_symbol","chromosome_name","entrezgene","ucsc","band")
filters <- c("chromosome_name","start","end")
values <- list(chromosome="1",start="1783590",end="2597819")
all.genes <- getBM(attributes=attributes, filters=filters, values=values, mart=mart)
Follow all the steps of yours, on the UCSC tables,
clade, genome, assembly
group -> Gene and gene prediction tracks
track-> UCSC Genes, table -> knownGene,
in region, position -> chr1:1,783,590-2,597,819 and in the out -> BED, click on get output
Go to *Create one BED record per*, and click the radio button of whole gene
There you go, genes in your speicified area in a text file, just copy and save.
Ofcourse, you can change various options like tables, regions as suiting to your needs
Cheers
Log in to answer this question.