Question: How can I get the list of genes between two SNPs?
gravatar for hamidhamzeiy
4.2 years ago by
hamidhamzeiy0 wrote:

Hello everyone,

I have a list of regions with a SNP designating the start of the region and a SNP designating the end of the region (an example is shown below). How can I obtain a list with all the genes within that region?


Chr    SNP1    SNP2

2    rs2370833   rs10173517

4   rs10000431   rs10012661





Thank you, Hamid

ADD COMMENTlink modified 2.2 years ago by Biostar ♦♦ 20 • written 4.2 years ago by hamidhamzeiy0
gravatar for Pierre Lindenbaum
4.2 years ago by
France/Nantes/Institut du Thorax - INSERM UMR1087
Pierre Lindenbaum127k wrote:

using ucsc mysql:

select distinct
snp144 as S1,
snp144 as S2,
knownGene as K,
kgXref as X
where in ("rs2370833","rs10173517") and in ("rs2370833","rs10173517") and
S1.chromStart < S2.chromStart and
S1.chrom = S2.chrom and
K.chrom = S1.chrom and
NOT( K.txEnd < S1.chromStart or K.txStart>=S2.chromEnd) and
X.kgID =;

chrom    chromStart    chromEnd    geneSymbol
chr2    209804520    230164977    UNC80
chr2    209804520    230164977    RPE
chr2    209804520    230164977    KANSL1L
chr2    209804520    230164977    RP11-260M2.1
chr2    209804520    230164977    AC007038.7
chr2    209804520    230164977    AC006994.2
chr2    209804520    230164977    ACADL
chr2    209804520    230164977    AC006994.3
chr2    209804520    230164977    Y_RNA
chr2    209804520    230164977    MYL1
chr2    209804520    230164977    LANCL1-AS1
chr2    209804520    230164977    LANCL1
chr2    209804520    230164977    CPS1
ADD COMMENTlink modified 3 months ago by RamRS26k • written 4.2 years ago by Pierre Lindenbaum127k
gravatar for alesssia
4.2 years ago by
London, UK
alesssia560 wrote:

You could use the biomaRt R package:, or the UCSC Genome Browser:

ADD COMMENTlink modified 3 months ago by RamRS26k • written 4.2 years ago by alesssia560
Please log in to add an answer.


Use of this site constitutes acceptance of our User Agreement and Privacy Policy.
Powered by Biostar version 2.3.0
Traffic: 981 users visited in the last hour