[BioC] trouble with yeastann function in AnnBuilder

James W. MacDonald jmacdon at med.umich.edu
Thu Feb 3 17:49:03 CET 2005


Jacob Michaelson wrote:
> I think I finally found what I need to build a decent Yeast 2.0 
> annotation package, but unfortunately, I keep getting errors.
> 
> The base file needed for yeastann is a two-column matrix containing 
> probe ids and SGD accession numbers.  I created such a file by 
> whittling down Affymetrix's Yeast 2.0 CSV annotation file into those 
> two columns.
> 
>  From the AnnBuilder documentation for yeastann:
> 
> Arguments
> 
> base
> base a matrix with two columns. The first column is probe ids and the 
> second one are the mappings to SGD ids used by all the Yeast Genome 
> data files. If base = "", the whole genome will be mapped based on a 
> data file that contains mappings between all the ORFs and SGD ids

Although it states here that base is supposed to be a matrix with two 
columns, really what it is supposed to be is a _file_ containing a 
matrix with two columns. The file should be in your working directory.
> 
> I then imported the above file into R using:
> 
>  > yeastsgd=read.csv("yeastsgd.csv")
> 
> and then
> 
>  > yeastsgd=as.matrix(yeastsgd)
> 
> ...just to be safe (although I also tried without and still got errors).
> 
> Then I pasted the default function from the yeastann documentation, 
> substituting my yeastsgd matrix into the base =" " position as follows:
> 
> yeastAnn(base = yeastsgd, yGenoUrl =
> +                  
> "ftp://genome-ftp.stanford.edu/pub/yeast/data_download/",
> +                  yGenoNames =
> +                  c("literature_curation/gene_literature.tab",
> +                  "chromosomal_feature/SGD_features.tab",
> +                  "literature_curation/gene_association.sgd"), toKeep =
> +                  list(c(6, 1), c(9, 2, 5, 6, 8, 11, 3), c(2, 5, 7)),
> +                  colNames = list(c("sgdid", "pmid"), c("sgdid",
> +                  "genename", "chr", "chrloc", "chrori", "description",
> +                  "alias"), c("sgdid", "go")), seps = c("\t", "\t",
> +                  "\t"), by = "sgdid")
> 
> which immediately produced the error message (FYI in the "base" 
> position I tried both with and without quotes, both of which produced 
> errors):
> 
> Error in file(file, "r") : unable to open connection
> In addition: Warning messages:
> 1: the condition has length > 1 and only the first element will be used 
> in: if (probe2ORF == "") {
> 2: only first element of `description' argument used
> 3: cannot open file `1769308_at'
> 
> I'm not sure why it keeps misunderstanding a matrix when the 
> documentation specifically calls for a matrix (for some reason it 
> thinks 1769308_at is a file and not a probe).
> 
> I verified that the imported data contains the data in the proper 
> placement, which it does, and the dimensions seem to be correct:
> 
>  > dim(yeastsgd)
> [1] 10928     2
> 
> Also FYI here's the error message when the above yeastann function is 
> implemented and yeastsgd is imported using read.csv, but not as.matrix:
> 
> Error in read.table(probe2ORF, sep = "\t", header = FALSE, strip.white 
> = TRUE) :
> 	argument 'file' must be a character string or connection
> In addition: Warning message:
> the condition has length > 1 and only the first element will be used 
> in: if (probe2ORF == "") {

So this error is basically saying that R looked for the file 'yeastsgd' 
in the current working directory, and couldn't find it.


HTH,

Jim


> 
> I'd really appreciate any help or suggestions.
> 
> Thanks!
> 
> --Jake Michaelson
> 
> 	[[alternative text/enriched version deleted]]
> 
> _______________________________________________
> Bioconductor mailing list
> Bioconductor at stat.math.ethz.ch
> https://stat.ethz.ch/mailman/listinfo/bioconductor


-- 
James W. MacDonald
Affymetrix and cDNA Microarray Core
University of Michigan Cancer Center
1500 E. Medical Center Drive
7410 CCGC
Ann Arbor MI 48109



More information about the Bioconductor mailing list