Entering edit mode
Natasha
▴
440
@natasha-4640
Last seen 10.3 years ago
Dear List,
I am using biomaRt for the first time.
Initially I had problems connecting to hsapiens dataset, though I
could
listMarts. However that issue was resolved (by solutions in some
earlier
posts) by changing the host to www.ensembl.org.
Now though I get the following error message when I try to execute the
following command:
>mg_eg.ens.t <- getBM(attributes =
c("entrezgene","ensembl_gene_id","ensembl_transcript_id","hgnc_symbol"
),
filters = "entrezgene", values = mg.u.eg$Entrez_Gene_ID, mart =
ensembl)
V1
1 <head>
2 <link rel="Shortcut" icon="" href="/errors/ensembl_ico.png" type="image/png"/>
3 The Ensembl Genome Browser
4 <style type="text/css">
5
body{color:#333333;background-color:#eaeeff;font-
family:Arial,Helvetica,Sans-serif;font-size:14pt;margin:0;padding:0}
6
#masthead{color:#ffffff;background-
color:#333366;width:100%;height:50px;padding:5px
0;font-size:1.75em;text-align:center;margin:auto}
Error in getBM(attributes = c("entrezgene", "ensembl_gene_id",
"ensembl_transcript_id", :
The query to the BioMart webservice returned an invalid result: the
number of columns in the result table does not equal the number of
attributes in the query. Please report this to the mailing list.
This I found strange as I did the same thing yesterday with another
object and it worked!!
Full Code and SessionInfo:
headmg.u.eg$Entrez_Gene_ID) #[1] 27122 3488 72
1293 100134134 390
lengthmg.u.eg$Entrez_Gene_ID) #[1] 4288
listMarts(host="www.ensembl.org")
ensembl = useMart("ENSEMBL_MART_ENSEMBL", host="www.ensembl.org")
listDatasets(ensembl)
ensembl = useMart("ENSEMBL_MART_ENSEMBL", host="www.ensembl.org",
dataset="hsapiens_gene_ensembl")
filt = listFilters(ensembl)
atts = listAttributes(ensembl)
mg_eg.ens <- getBM(attributes =
c("entrezgene","ensembl_gene_id","hgnc_symbol"), filters =
"entrezgene",
values = mg.u.eg$Entrez_Gene_ID, mart = ensembl) # 4016 3
mg_eg.ens.t <- getBM(attributes =
c("entrezgene","ensembl_gene_id","ensembl_transcript_id","hgnc_symbol"
),
filters = "entrezgene", values = mg.u.eg$Entrez_Gene_ID, mart =
ensembl)
sessionInfo()
R version 2.13.0 (2011-04-13)
Platform: x86_64-pc-linux-gnu (64-bit)
locale:
[1] LC_CTYPE=en_GB.UTF-8 LC_NUMERIC=C
[3] LC_TIME=en_GB.UTF-8 LC_COLLATE=en_GB.UTF-8
[5] LC_MONETARY=C LC_MESSAGES=en_GB.UTF-8
[7] LC_PAPER=en_GB.UTF-8 LC_NAME=C
[9] LC_ADDRESS=C LC_TELEPHONE=C
[11] LC_MEASUREMENT=en_GB.UTF-8 LC_IDENTIFICATION=C
attached base packages:
[1] stats graphics grDevices utils datasets methods base
other attached packages:
[1] biomaRt_2.8.0 DESeq_1.4.1 locfit_1.5-6 lattice_0.19-23
[5] akima_0.5-4 Biobase_2.12.1 WriteXLS_2.1.0 gdata_2.8.2
[9] limma_3.8.2
loaded via a namespace (and not attached):
[1] annotate_1.30.0 AnnotationDbi_1.14.1 DBI_0.2-5
[4] genefilter_1.34.0 geneplotter_1.30.0 grid_2.13.0
[7] gtools_2.6.2 RColorBrewer_1.0-2 RCurl_1.6-4
[10] RSQLite_0.9-4 splines_2.13.0 survival_2.36-5
[13] tools_2.13.0 XML_3.4-0 xtable_1.5-6
Many Thanks,
Natasha
--