Last data update: 2014.03.03

R: Compute PM correction and summary expression value
generateExprVal.method.pdnnR Documentation

Compute PM correction and summary expression value

Description

Computes PM correction and summary expression value with PDNN method.

Usage

pmcorrect.pdnn(object, params, gene=NULL, gene.i=NULL,
               params.chiptype=NULL, outlierlim=3, callingFromExpresso=FALSE)
pmcorrect.pdnnpredict(object, params, gene=NULL, gene.i=NULL,
               params.chiptype=NULL, outlierlim=3, callingFromExpresso=FALSE)
generateExprVal.method.pdnn(probes, params)

Arguments

object

object of ProbeSet.

probes

matrix of PM-corrected signals (should be coming out of pmcorrect.pdnn).

params

experiments specific parameters.

gene

gene (probe set) ID (from wich the gene.i would be derived).

gene.i

gene index (see details).

params.chiptype

chip-specific parameters.

outlierlim

threshold for tagging a probe as an outlier.

callingFromExpresso

is the function called through expresso. DO NOT play with that.

Details

Only one of gene, gene.i should be specified. For most the users, this is gene. pmcorrect.pdnn and pmcorrect.pdnnpredict return what is called GSB and GSB + NSB + B in the paper by Zhang Li and collaborators.

Value

pmcorrect.pdnn and pmcorrect.pdnnpredict return a matrix (one row per probe, one column per chip) with attributes attached. generateExprVal returns a list:

exprs

expression values

se.exprs

se expr. val.

See Also

pdnn.params.chiptype

Examples

data(hgu95av2.pdnn.params)
library(affydata)
data(Dilution)

## only one CEL to go faster
abatch <- Dilution[, 1]

## get the chip specific parameters
params <- find.params.pdnn(abatch, hgu95av2.pdnn.params)

## The thrill part: do we get like in the Figure 1-a of the reference ?
par(mfrow=c(2,2))
##ppset.name <- sample(featureNames(abatch), 2)
ppset.name <- c("41206_r_at", "31620_at")
ppset <- probeset(abatch, ppset.name)
for (i in 1:2) {
  ##ppset[[i]] <- transform(ppset[[i]], fun=log) # take the log as they do
  probes.pdnn <- pmcorrect.pdnnpredict(ppset[[i]], params,
                                       params.chiptype=hgu95av2.pdnn.params)
  ##probes.pdnn <- log(probes.pdnn)
  plot(ppset[[i]], main=paste(ppset.name[i], "\n(raw intensities)"))
  matplotProbesPDNN(probes.pdnn, main=paste(ppset.name[i], "\n(predicted intensities)"))
}

## pick the 50 first probeset IDs
## (to go faster)
ids <- featureNames(abatch)[1:100]

## compute the expression set (object of class 'ExpressionSet')
eset <- computeExprSet(abatch, pmcorrect.method="pdnn",
                       summary.method="pdnn", ids=ids,
                       summary.param = list(params, params.chiptype=hgu95av2.pdnn.params))

Results


R version 3.3.1 (2016-06-21) -- "Bug in Your Hair"
Copyright (C) 2016 The R Foundation for Statistical Computing
Platform: x86_64-pc-linux-gnu (64-bit)

R is free software and comes with ABSOLUTELY NO WARRANTY.
You are welcome to redistribute it under certain conditions.
Type 'license()' or 'licence()' for distribution details.

R is a collaborative project with many contributors.
Type 'contributors()' for more information and
'citation()' on how to cite R or R packages in publications.

Type 'demo()' for some demos, 'help()' for on-line help, or
'help.start()' for an HTML browser interface to help.
Type 'q()' to quit R.

> library(affypdnn)
Loading required package: affy
Loading required package: BiocGenerics
Loading required package: parallel

Attaching package: 'BiocGenerics'

The following objects are masked from 'package:parallel':

    clusterApply, clusterApplyLB, clusterCall, clusterEvalQ,
    clusterExport, clusterMap, parApply, parCapply, parLapply,
    parLapplyLB, parRapply, parSapply, parSapplyLB

The following objects are masked from 'package:stats':

    IQR, mad, xtabs

The following objects are masked from 'package:base':

    Filter, Find, Map, Position, Reduce, anyDuplicated, append,
    as.data.frame, cbind, colnames, do.call, duplicated, eval, evalq,
    get, grep, grepl, intersect, is.unsorted, lapply, lengths, mapply,
    match, mget, order, paste, pmax, pmax.int, pmin, pmin.int, rank,
    rbind, rownames, sapply, setdiff, sort, table, tapply, union,
    unique, unsplit

Loading required package: Biobase
Welcome to Bioconductor

    Vignettes contain introductory material; view with
    'browseVignettes()'. To cite Bioconductor, see
    'citation("Biobase")', and for packages 'citation("pkgname")'.

registering new summary method 'pdnn'.
registering new pmcorrect method 'pdnn' and 'pdnnpredict'.
> png(filename="/home/ddbj/snapshot/RGM3/R_BC/result/affypdnn/generateExprVal.method.pdnn.Rd_%03d_medium.png", width=480, height=480)
> ### Name: generateExprVal.method.pdnn
> ### Title: Compute PM correction and summary expression value
> ### Aliases: generateExprVal.method.pdnn pmcorrect.pdnn
> ###   pmcorrect.pdnnpredict
> ### Keywords: manip
> 
> ### ** Examples
> 
> data(hgu95av2.pdnn.params)
> library(affydata)
     Package    LibPath                            Item      
[1,] "affydata" "/home/ddbj/local/lib64/R/library" "Dilution"
     Title                        
[1,] "AffyBatch instance Dilution"
> data(Dilution)
> 
> ## only one CEL to go faster
> abatch <- Dilution[, 1]
> 
> ## get the chip specific parameters
> params <- find.params.pdnn(abatch, hgu95av2.pdnn.params)
initializing data structure...
done.
dealing with CEL 1 :
  step 1...done.
  step 2...done.
There were 50 or more warnings (use warnings() to see the first 50)
> 
> ## The thrill part: do we get like in the Figure 1-a of the reference ?
> par(mfrow=c(2,2))
> ##ppset.name <- sample(featureNames(abatch), 2)
> ppset.name <- c("41206_r_at", "31620_at")
> ppset <- probeset(abatch, ppset.name)
> for (i in 1:2) {
+   ##ppset[[i]] <- transform(ppset[[i]], fun=log) # take the log as they do
+   probes.pdnn <- pmcorrect.pdnnpredict(ppset[[i]], params,
+                                        params.chiptype=hgu95av2.pdnn.params)
+   ##probes.pdnn <- log(probes.pdnn)
+   plot(ppset[[i]], main=paste(ppset.name[i], "\n(raw intensities)"))
+   matplotProbesPDNN(probes.pdnn, main=paste(ppset.name[i], "\n(predicted intensities)"))
+ }
> 
> ## pick the 50 first probeset IDs
> ## (to go faster)
> ids <- featureNames(abatch)[1:100]
> 
> ## compute the expression set (object of class 'ExpressionSet')
> eset <- computeExprSet(abatch, pmcorrect.method="pdnn",
+                        summary.method="pdnn", ids=ids,
+                        summary.param = list(params, params.chiptype=hgu95av2.pdnn.params))
100 ids to be processed
|                    |
|####################|
> 
> 
> 
> 
> 
> 
> dev.off()
null device 
          1 
>