[BioC] Visualizing and distances using GO graph question,

Saurin Jani saurin_jani at yahoo.com
Wed Oct 6 00:56:21 CEST 2004


Hi,

I have attached GO graph with MF ontology, that I got
it for my Knock-out and Wilde Type samples.

How should I go for displaying GOTerm on top EACH of
Pie chart NODE? I can display GOID but I would like to
have GOTerm. If anyone has done this before..plz let
me   know. 

below is code:

if(require(Rgraphviz)){

 opar = par(xpd = NA)
 plotPieChart <- function(curPlot,counts,main) {

 renderNode <- function(x) {

 force(x)
 y <- x * 400 + 1
 function(node,ur,attrs = list(),radConv = 1) {
          nodeCenter <- getNodeCenter(node)
          pieGlyph(y,xpos = getX(nodeCenter),ypos =
getY(nodeCenter),
                   radius = getNodeRW(node),col =
c("pink","green"))
         
drawTxtLabel(txtLabel(node),getX(nodeCenter),getY(nodeCenter))
          }

      }
drawing <- vector(mode = "list",length =
nrow(counts));
for(i in 1:length(drawing)){
    drawing[[i]] <- renderNode(counts[i,])
    }
if(missing(main))
  main = "GO: Molecular Function : Mouse Embryo
Fibroblast Pie Chart Plot"
  plot(curPlot,drawNode = drawing,main = main)
 legend(300,65,legend = c("KO","WT"), fill =
c("pink","green"))
 }

plotPieChart(pgLayoutMF,ctmat)
par(opar)
}


thanks
Saurin


		
_______________________________

Declare Yourself - Register online to vote today!


More information about the Bioconductor mailing list