Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- ###################################################
- ### chunk number 3: annotations
- ###################################################
- stopifnot(require(Biobase, lib.loc = mylib))
- source(file.path(codeDir,"AnalysisFunctions2Pack.R"))
- arrayType <- "{$f_179}"
- chipPackAvailable <- "{$f_20}" # Si existeix un paquet BioC pel xip es posa a TRUE
- if (chipPackAvailable){
- anotPackage <- "{$f_21}" # Pot ser per exemple 'hgu133plus2' o 'mouse4302'
- anotations.FileName <- "{$f_22}" # Si hi ha chipPackage ha de ser NULL
- symbolsTable <- "{$f_23}" # Si hi ha chipPackage ha de ser NULL
- entrezTable <- "{$f_24}" # Si hi ha chipPackage ha de ser NULL
- }else{
- ### Si no hi ha paquet BioC pel xip
- anotPackage <- "{$f_21}" # Un paquet d'organisme com 'org.Hs.eg' o 'org.Mm.eg'
- anotations.FileName <- "{$f_22}" # Un paquet d'anotacions fet a ma 'HEAnnotation.txt'
- if (!is.null(anotations.FileName)) {
- if (!(exists("symbolsTable")))
- symbolsTable <- creaAnot(dataDir, anotations.FileName, "Gene.Symbol")
- if (!(exists("entrezTable")))
- entrezTable <- creaAnot(dataDir, anotations.FileName, "Entrez.Gene.ID")
- my.annotations<-cbind(Entrez=entrezTable, Symbols=symbolsTable)
- write.table(my.annotations, file=file.path(dataDir, "my.annotations.txt"), sep="\t", quote=F)
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment