R/ChipEffectSet.TOFULL.R

setMethodS3("getAsFullCelSet", "ChipEffectSet", function(this, ..., verbose=FALSE) {
  # - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
  # Validate arguments
  # - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
  # Argument 'verbose':
  verbose <- Arguments$getVerbose(verbose)
  if (verbose) {
    pushState(verbose)
    on.exit(popState(verbose))
  }

  verbose && enter(verbose, "Getting chip effect set expanded to the full CDF")
  cells <- NULL
  files <- list()
  for (kk in seq_along(this)) {
    cef <- this[[kk]]
    verbose && enter(verbose, sprintf("Array #%d ('%s') %d",
                                          kk, getName(cef), length(this)))

    cf <- getAsFullCelFile(cef, ..., cells=cells, verbose=less(verbose, 5))

    cells <- attr(cf, "cells")
    attr(cf, "cells") <- NULL

    files[[kk]] <- cf
    verbose && exit(verbose)
  }
  verbose && exit(verbose)

  res <- AffymetrixCelSet(files)

  res
}, protected=TRUE)
HenrikBengtsson/aroma.affymetrix documentation built on Feb. 20, 2024, 9:07 p.m.