R/result2html.R

Defines functions result2html

Documented in result2html

result2html<-function(cdf.name, result, filename="result"){
    
    library(cdf.name,character.only =TRUE)
	require("annaffy")
    good <-result$significant
    if (sum(good)==0) print("No significant result is generated")
    else{
        fullresult<-cbind(result$ID, result$Log2Ratio.1, result$adj.P.Val)
        gN <- as.character(result$ID)
        aaf.handler()
        anncols <- aaf.handler()[c(1:3, 7, 8)]
        probeid <- gN[good]
        anntable <- aafTableAnn(probeid, cdf.name, anncols)
        testtable <- aafTable( "Log2 ratio"=fullresult[,2][good],
        "P.Value"=fullresult[,3][good])
        table<-merge(anntable, testtable)
        saveHTML(table, paste(filename,"html", sep="."), title="Target Genes")
    }
}

Try the AffyExpress package in your browser

Any scripts or data that you put into this service are public.

AffyExpress documentation built on Nov. 8, 2020, 7:50 p.m.