[BioC] AnnBuilder with custmerized GO annotation

Nianhua Li nli at fhcrc.org
Wed May 2 19:11:17 CEST 2007


Hi, Xinxia,

I believe the problem is related to the data. The data is was created a couple
of years ago. I guess maybe we updated the parser according to the changes on GO
website, but didn't update the data. The data is mean to be an example and
definitely won't be consistent with latest GO data. We will try to update the
vignette in the future.

In regarding to your task, I would modify AnnBuilder code if I were you. The
related codes are in function getAnnData() in file AnnBuilder/R/ABPkgBuilder.R:

    # Parse gene2go.gz
    parser(srcObjs[["eg"]]) <- getBaseParsers("eggo")
    go <- try(parseData(srcObjs[["eg"]], srcObjs[["eg"]]@go,
                                ncol = 2, mergeKey = FALSE))
    colnames(go) <- c("PROBE", "GO")
    options(show.error.messages = TRUE)
    if(inherits(annotation, "try-error")){
        stop(paste("Parsing Entrez Gene gene2go.gz failed because of:\n\n",
                   annotation))
    }
    if(nrow(go) > 0)
      annotation <- merge(annotation, go, by = "PROBE", all.x = TRUE)
    options(show.error.messages = FALSE)

Remove the first 2 lines. Create a data frame of 2 columns. The first column is
probeset id, the second column is go id. Assign this data frame to variable
"go". Then you are good to go. When you invoke ABPkgBuilder, give your probeset
to Entrez Gene mapping as base mapping file and "ll" as baseMapType. Maybe you
want to insert "browser()" into the code (say at the beginning of getAnnData())
to help you on debugging. I find it very useful when I work with AnnBuilder. 

hope this helps

nianhua



More information about the Bioconductor mailing list