adjustSignal:

Usage Arguments Examples

Usage

1
adjustSignal(object, Scale = TRUE, Cy = TRUE, Ref = "cy3", GC = TRUE, gcDB = agilentDB, preSeg = TRUE, suppOutliers = FALSE)

Arguments

object
Scale
Cy
Ref
GC
gcDB
preSeg
suppOutliers

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
##---- Should be DIRECTLY executable !! ----
##-- ==>  Define data, use random,
##--	or do  help(data=index)  for the standard data sets.

## The function is currently defined as
function (object, Scale = TRUE, Cy = TRUE, Ref = "cy3", GC = TRUE, 
    gcDB = agilentDB, preSeg = TRUE, suppOutliers = FALSE) 
{
    cnSet <- getCNset(object)
    if (grepl("Agilent", getInfo(object, "platform"))) {
        if (Cy) {
            cnSet <- .CyAdjust(cnSet, Ref)
            object@param$CyAdjusted = TRUE
        }
        if (GC) {
            cnSet <- .GCadjust(cnSet, gcDB)
            object@param$GCAdjusted = TRUE
        }
    }
    else {
        object@param$CyAdjusted = FALSE
        object@param$GCAdjusted = FALSE
    }
    object@param$dLRs <- .dlrs(cnSet$Log2Ratio)
    object@param$MAD <- .MAD(cnSet$Log2Ratio)
    if (Scale) {
        cat("Scaling...")
        cnSet$Log2Ratio <- scale(cnSet$Log2Ratio, center = FALSE)
        if (grepl("Affymetrix", getInfo(object, "platform"))) 
            cnSet$Log2Ratio <- cnSet$Log2Ratio * 1.25
        cat("Done.\n")
    }
    if (suppOutliers) 
        cnSet$Log2Ratio <- .supprOutliers(cnSet$Log2Ratio, n = ifelse(grepl("Agilent", 
            getInfo(object, "platform")), 5, 25))
    if (preSeg) {
        cnSet <- .preSeg(cnSet, getInfo(object, "sampleName"), 
            getParam(object))
    }
    object@cnSet <- cnSet
    cat("dLRs:", object@param$dLRs, "\tMAD:", object@param$MAD, 
        "\n")
    return(object)
  }

brian-bot/rCGH documentation built on May 13, 2019, 5:11 a.m.