create.optimized.setup: Create optimized setup

Description Usage Arguments Details Value Examples

View source: R/gSetup-class.R

Description

Create a optimized sample assignment.

Usage

1
create.optimized.setup(fun = "default", sample, container, ...)

Arguments

fun

The name of the optimization function. When omitted, it is the same as default or optimal.shuffle. Currently alternative optimization function is optimal.block. User can define their own optimization function.

sample

A gSample object contains sample related information.

container

A gContainer object contains experiment related container (chips, plate, exclusion etc) information.

...

Additional parameters passed to optimization function.

Details

Currently two methods are available: optimal.shuffle (default) and optimal.block methods. The function is equivalent to create.experiment.setup() followed by corresponding optimization function of the same name.

Value

A gExperimentSetup object is returned to store all related information.

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
library("OSAT")
# data as an example
inPath <- system.file("extdata", package="OSAT")
pheno <- read.table(file.path(inPath, 'samples.txt'), header=TRUE, sep="\t")

## create object to hold sample information
gs <- setup.sample(pheno,  optimal=c("SampleType", "Race", "AgeGrp"), strata=c("SampleType") )
gs

gc <- setup.container(IlluminaBeadChip96Plate, 6, batch='plates')
gc
# demonstration only. nSim=5000 or more are commonly used.
gSetup <- create.optimized.setup(sample=gs, container=gc, nSim=500)

llrs/OSAT documentation built on May 23, 2019, 7:18 a.m.