Question: Get Germline variants from Biomart
0
gravatar for Sharon
8 days ago by
Sharon480
Sharon480 wrote:

Hi Everyone

I am trying to get all genes that has gremlin variant from biomart using code:

SNPs <- getBM(attributes=c('ensembl_gene_id'), filters = 'germ_line_variation_source',values='with_validated_snp', mart = mygenome)

SNPs <- getBM(attributes=c('ensembl_gene_id'), filters = 'germ_line_variation_source',values=’SGRP’, mart = mygenome)

SNPs <- getBM(attributes=c('ensembl_gene_id'), filters = 'germ_line_variation_source',values=TRUE, mart = mygenome)

all the above fails. Although, something similar works with me for GO:

GO <- getBM(attributes=c('ensembl_gene_id'), filters = 'go', values ="GO:0006119", mart = mygenome)

Any hint how to use the snps filter?

Thanks

getbm filter • 78 views
ADD COMMENTlink modified 7 days ago • written 8 days ago by Sharon480
1
gravatar for Sharon
7 days ago by
Sharon480
Sharon480 wrote:

Hi everyone

In case anyone else stuck at this like me, this works:

SNPs <- getBM(attributes=c('ensembl_gene_id', 'germ_line_variation_source'),filters = 'germ_line_variation_source',values='SGRP', mart = mygenome)

Thanks

ADD COMMENTlink written 7 days ago by Sharon480
1

Thank you for answering the question - it will be useful for future visitors. Please accept your own answer so the question is marked solved on the website. To do that, click on the green check mark on the left side of the answer:

Upvote|Bookmark|Accept

ADD REPLYlink written 7 days ago by RamRS27k

Thanks RamRS, done :)

ADD REPLYlink written 7 days ago by Sharon480

Your query #2 in the question should work as well. I have a feeling the quotes interfere with the query. If you're copy-pasting from Microsoft products (or other word processors), ensure all quotes are simple single or double quotes (' and ") and not stylized quotes ( ’ ).

See the difference here:

## first line is your query, second line is mine
SNPs <- getBM(attributes=c('ensembl_gene_id'), filters = 'germ_line_variation_source',values=’SGRP’, mart = mygenome)
SNPs <- getBM(attributes=c('ensembl_gene_id'), filters = 'germ_line_variation_source',values='SGRP', mart = mygenome)
ADD REPLYlink modified 7 days ago • written 7 days ago by RamRS27k

ensure all quotes are simple single or double quotes (' and ") and not stylized quotes ( ’ ).

Second that. Turn off "smart quotes and dashes" in Apple --> System Preferences --> Keyboard --> text, if you are using macOS.

ADD REPLYlink written 7 days ago by genomax85k

I am using linux, and vim. :) Thanks genomax

ADD REPLYlink modified 7 days ago • written 7 days ago by Sharon480
Please log in to add an answer.

Help
Access

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