R/plot3d_nvalidation.R

if (!isGeneric("plot3d")) {
  setGeneric("plot3d", function(object, ...) standardGeneric("plot3d")); 
}

setMethod("plot3d", signature(object="nvalidation"),
    function (object, ...) 
    {
 g=object@nselected #rows:genes; cols:number of genes to be selected in molecular signatur
  h=apply(g,1, function(x) {sum(x)} )

  ### 3D PLOT
  y=c(1:ncol(g)) #number of genes to be selected in molecular signatur
  x=c(1:nrow(g)) #genes
  z=g
  rep=paste("validation repeat 1:",object@nrep);
  persp(x, y, z, xlab="genes", ylab="number of top genes", zlab=rep,
  theta = 30, phi = 30, expand = 0.5, col = "lightblue", main="absolute frequency of genes in signature")
    }
)

Try the cancerclass package in your browser

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

cancerclass documentation built on Nov. 8, 2020, 5:31 p.m.