Hello,
I am trying to use biomaRt to convert human ensembl gene ids to rat gene ids. I have previously used this and it worked perfectly. But, now I am getting an error message. My problem with an exemplar is given below.
library("biomaRt")
human <- useMart(host="www.ensembl.org", "ENSEMBL_MART_ENSEMBL", dataset="hsapiens_gene_ensembl")
rat <- useMart(host="www.ensembl.org", "ENSEMBL_MART_ENSEMBL", dataset="rnorvegicus_gene_ensembl")
getLDS(attributes=c("ensembl_gene_id","hgnc_symbol"), filters="ensembl_gene_id", values= "ENSG00000165029", mart=human, attributesL=c("entrezgene","rgd_symbol"), martL=rat)
I get the error message:
Error in getLDS(attributes = c("ensembl_gene_id", "hgnc_symbol"), filters = "ensembl_gene_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.
Only "getLDS" function produces error. For example, when I try "getBM" it works fine.
getBM(filters= "ensembl_gene_id", attributes= c("ensembl_gene_id", "entrezgene", "hgnc_symbol"),values= "ENSG00000165029",mart= human)
OUTPUT:
ensembl_gene_id entrezgene hgnc_symbol
1 ENSG00000165029 19 ABCA1
Any help is greatly appreciated.
Thanks
Diwan
sessionInfo()
R version 3.2.2 (2015-08-14)
Platform: x86_64-w64-mingw32/x64 (64-bit)
Running under: Windows 7 x64
locale:
[1] LC_COLLATE=English_United States.1252 LC_CTYPE=English_United States.1252
[3] LC_MONETARY=English_United States.1252 LC_NUMERIC=C
[5] LC_TIME=English_United States.1252
attached base packages:
[1] parallel stats4 stats graphics grDevices utils datasets methods base
other attached packages:
[1] RCurl_1.95-4.7 bitops_1.0-6
[3] BiocInstaller_1.18.5 biomaRt_2.24.0
[5] annotate_1.46.1 XML_3.98-1.3
[7] pd.ragene.2.1.st_3.14.1 oligo_1.32.0
[9] oligoClasses_1.30.0 Biostrings_2.36.4
[11] XVector_0.8.0 ragene21sttranscriptcluster.db_8.3.1
[13] ragene21stprobeset.db_8.3.1 org.Rn.eg.db_3.1.2
[15] RSQLite_1.0.0 DBI_0.3.1
[17] AnnotationDbi_1.30.1 GenomeInfoDb_1.4.2
[19] IRanges_2.2.7 S4Vectors_0.6.4
[21] Biobase_2.28.0 BiocGenerics_0.14.0
loaded via a namespace (and not attached):
[1] affxparser_1.40.0 splines_3.2.2 GenomicRanges_1.20.6 zlibbioc_1.14.0
[5] bit_1.1-12 xtable_1.7-4 foreach_1.4.2 tools_3.2.2
[9] ff_2.2-13 iterators_1.0.7 preprocessCore_1.30.0 affyio_1.36.0
[13] codetools_0.2-14
Thanks very much for pushing the patch Thomas, it looks like it's working fine for me now.