R/twilight.getmatrix.R

Defines functions twilight.getmatrix

Documented in twilight.getmatrix

twilight.getmatrix <- function(xin){
  ## Extracts the data matrix from an expression set.
  if (class(xin)[1]=="ExpressionSet"){
    xout <- exprs(xin)
    rownames(xout) <- featureNames(xin)
    colnames(xout) <- sampleNames(xin)
    result <- xout
  } 
  else {
	result <- xin
  }
  return(result)
}

Try the twilight package in your browser

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

twilight documentation built on Nov. 8, 2020, 5:38 p.m.