Thank you for this.
I think I may end up doing this anyway as I am trying to get rid of my irrational fear of commands.
Hi All
I am trying to upload a list of positions to table browser so that I can get their related SNPs. When I try to look for each position using the "position" option in the region section of the Table Browser I get the appropriate SNP. But when I try to do the same using tab delimited files saved as .bed files I get nothing. Even when I paste in to the regions box, I get nothing # No results in given region.
Does anyone know a reason for this?
I can do it one by one, but I don't really fancy doing this 89,000 times. So a solution would be most useful.
Thanks
If you can do things on the command line, you could use BEDOPS bedmap.
First, sort your positions file with sort-bed:
$ sort-bed unsorted-positions.bed > positions.bed
Second, download SNP data from UCSC to a BED file. For example, if you are working with human hg19 data:
$ mysql --user=genome --host=genome-mysql.cse.ucsc.edu -A -D hg19 -e 'SELECT chrom, chromStart, chromEnd, name FROM snp138Common' | tail -n +2 > snp138Common.bed
Third, map the SNPs to each position with bedmap:
$ bedmap --echo --echo-map-id-uniq positions.bed snp138Common.bed > answer.bed
The file answer.bed contains each position on its own line, along with the rs* IDs that overlap each position.
Thank you for this.
I think I may end up doing this anyway as I am trying to get rid of my irrational fear of commands.
Log in to answer this question.
Command lines scare me, but will do if absolutely unavoidable.
Do you know why the normal pasting in to
identifiers (names/accessions) field to get positions or
"Define region" to get rs lists for a list of positions doesn't work?
I don't know. You might double-check the format of your input files. Are they tab-delimited? Did you get them out of an Excel spreadsheet, which means they will contain non-standard line delimiters? A lot of these things can be checked but may require some command-line work.
Thanks. It is a formatting issue as I know the SNPs do exist at these positions. I just can't figure out what.
What would you recommend if I don't use excel? Or do you know where I can look to rectify the problem?