Learn R Programming

ArrayTools (version 1.32.0)

designMatrix: Class to Contain the Design Matrix that Used for Linear Regression

Description

Class to Contain the Design Matrix that Used for Linear Regression

Arguments

Creating Objects

new("designMatrix", ..., target, covariates, intIndex=0) This create as design matrix class. target is a data frame that contains chip and covaraite information, or experimental phenotypes recorded in eSet and ExpressionSet-derived classes. covariates is a list of 1-n covariates. If intIndex=0, the interaction effect is not considered; otherwise, use two integers to indicate which covariates are considered for interaction effect. For example, if covariates <- c("estrogen","drug","time") and you are considering the interaction between "estrogen" and "time", then you would write intIndex=c(1,3)

Slots

design:
contains the design matrix
target:
contains the target data
covariates:
contains the covariates
intIndex:
contains the intIndex

Methods

getCovariates
signature(object = "designMatrix"): access the covariates slot
getDesign
signature(object = "designMatrix"): access the design slot
getIntIndex
signature(object = "designMatrix"): access the intIndex slot
getTarget
signature(object = "designMatrix"): access the target slot
initialize
signature(.Object = "designMatrix"): create a new designMatrix class
show
signature(object = "designMatrix"): print the designMatrix class

See Also

contrastMatrix

Examples

Run this code
data(eSetExample)
## One-way Anova
(design1<- new("designMatrix", target=pData(eSetExample), covariates = "Treatment"))

## Randomized block design
(design2<- new("designMatrix", target=pData(eSetExample), 
   covariates = c("Treatment", "Group")))

## Interaction design
(design3<- new("designMatrix", target=pData(eSetExample), 
   covariates = c("Treatment", "Group"), intIndex=c(1,2)))
   

Run the code above in your browser using DataLab