# download the pathway gene-sets data #
## Not run:
# gset.url <- "http://www.broadinstitute.org/gsea/msigdb/download_file.jsp?filePath=/resources/msigdb/3.0/c5.all.v3.0.orig.gmt"
# gset.file.name <- unlist(strsplit(gset.url,split="/"))
# gset.file.name <- gset.file.name[length(gset.file.name)]
# gset.destination <- paste(local.data.dir,gset.file.name,sep="")
# download.file(gset.url, gset.destination)
# gset.file <- gset.destination
# gset.data <- getGmt(gset.file)
#
# # read in human U133+2 array annotation file#
# human.ann.data <- read.table("local human U133+2 array annotation data", head=T, sep="\t")
# genes.in.ann <- human.ann.data[,3] # get the gene symbols from annotation file
#
# # map the genes to probe-set IDs using human annotation data.##########
# for (i in 1:length(gset.data))
# {
# genes.this.gset <- geneIds(gset.data[[i]])
# match.rows <- is.element(genes.in.ann, genes.this.gset)
# probe.this.gset <- human.ann.data$ID[match.rows]
# geneIds(gset.data[[i]]) <- as.character(probe.this.gset)
# }
# ## End(Not run)
Run the code above in your browser using DataLab