[BioC] arabidopsis annotate mget problem

James W. MacDonald jmacdon at med.umich.edu
Fri Jun 20 00:47:32 CEST 2008


Hi Siobhan,

Siobhan Braybrook wrote:
> please excuse me if this is elementary, but I am lost about an error I am
> getting.
> I want to use a list of probe IDs to get out the genes from ath1121501ACCNUM.
>
> So I did the following:
>
> library(annotate)
> library(ath1121501.db)
> #next I made a short list of probe IDs to test my mget ability
> abaup=c("262128_at","255795_at","266462_at","250648_at","247095_at","258498_at","247723_at","258347_at","245982_at","263497_at")
>   

This isn't a list - it is a character vector.

> a1=mget(abaup, ath1121501ACCNUM)
> #this worked just fine
> #so I made a txt file of all the probe IDs I wanted to look up, and read in
> abaupr= read.delim("upgenes.txt", header = FALSE, quote="",sep = "\t")
> #then I made it a list
> abaupr=as.list(abaupr)  
> #then I did just like I did on my test case above but got an error about
> #ifnotfound.  
> a1=mget(abaupr, ath1121501ACCNUM)
> #Error in .checkKeys(value, Lkeys(x), x at ifnotfound) : 
> #  the keys must be character strings
>   

This error is trying to tell you that you are supposed to be feeding 
mget() a character vector rather than a list, which is why it worked 
above and didn't work here. Just remove the as.list() part and you 
should be good.

Best,

Jim


> #I looked up ifnotfound in mget.....and still dont understand #the error.  
> #the only option is NA, but.........
> a1=mget(abaupr, ath1121501ACCNUM,ifnotfound=NA)
> #Error in .checkKeys(value, Lkeys(x), x at ifnotfound) : 
> #  the keys must be character strings
>
> My lack of understanding could be due to my lack of getting mget.....any help?
>
> Thanks!
> Siobhan
>
> S.A. Braybrook
> Section of Plant Biology
> University of California, Davis
> Davis, CA
> 530-752-6980
>
> "The time is always right to do what is right."
> -Dr. Martin Luther King Jr.
>
> _______________________________________________
> Bioconductor mailing list
> Bioconductor at stat.math.ethz.ch
> https://stat.ethz.ch/mailman/listinfo/bioconductor
> Search the archives: http://news.gmane.org/gmane.science.biology.informatics.conductor
>



More information about the Bioconductor mailing list