This is a test version of Biostars. For the public version, visit https://www.biostars.org.
Problem In Obtaining Gene Names From Ucsc

Hi I want to obtain all the exons for mouse (mm10) with chromosome start_pos and end_pos followed by gene name. In UCSC table browser I have selected group: genes and gene prediction track; track: refseq genes; table refseq. In the output format tab i just selected custom track. I was getting the output as follows after i select the Exons plus and hit the get custom track in file button

chr1    134199221    134203590    NM_001039510_exon_0_0_chr1_134199222_r    0    -
chr1    134234014    134234412    NM_001039510_exon_1_0_chr1_134234015_r    0    -
chr1    134235227    134235431    NM_001039510_exon_2_0_chr1_134235228_r    0    -

However, i wanted it as

   chr1        134199221    134203590    Adora1_exon_0_0_chr1_134199222_r    0    -
   chr1       134234014    134234412    Adora1_exon_1_0_chr1_134234015_r    0    -
    chr1    134235227    134235431   Adora1_exon_2_0_chr1_134235228_r    0    -
ucsc genes

you need to select the name2 in the output (while selecting custom columns)!!

Unless you know differently, I don't think it's possible to get exon coordinates in BED format with gene names instead of transcript IDs

I don't get custom column selection option here in this case

2 answers

Can you please let us know from Where you got this dat ?

chr1       134199221    134203590    Adora1_exon_0_0_chr1_134199222_r    0    -
chr1       134234014    134234412    Adora1_exon_1_0_chr1_134234015_r    0    -
chr1       134235227    134235431    Adora1_exon_2_0_chr1_134235228_r    0    -

I understand this is different name of same gene !!

When I've wanted to substitute gene names for transcript IDs in a BED file, I used a dictionary I got from selecting "selected fields from primary and related tables" under output format in the table browser, then selecting only the "name" and "name2" fields on the page linked from there, which will provide a list of transcript IDs and their corresponding gene names. You may have to write a quick script to do the substitution in perl, R, etc.

Yeah i was doing the same thing but just wanted to know whether there is a method without code within the ucsc browser!

Not sure that there is one...that's two of us who'd like to know now!

Log in to answer this question.