oneWayAnova {MKomics} | R Documentation |
A function for Analysis of Variance
Description
This function is a slight modification of function Anova
of
package genefilter.
Usage
oneWayAnova(cov, na.rm = TRUE, var.equal = FALSE)
Arguments
cov |
The covariate. It must have length equal to the number of
columns of the array that the result of |
na.rm |
a logical value indicating whether |
var.equal |
a logical variable indicating whether to treat the variances
in the samples as equal. If |
Details
The function returned by oneWayAnova
uses oneway.test
to perform a one-way ANOVA, where x
is the set of gene expressions.
The F statistic for an overall effect is computed and the corresponding
p-value is returned.
The function Anova
of package genefilter instead compares the computed
p-value to a prespecified p-value and returns TRUE
, if the computed p-value
is smaller than the prespecified one.
Value
oneWayAnova
returns a function with bindings for cov
that will
perform a one-way ANOVA.
The covariate can be continuous, in which case the test is for a linear effect for the covariate.
Note
A first version of this function appeared in package SLmisc.
Author(s)
Matthias Kohl Matthias.Kohl@stamats.de
References
R. Gentleman, V. Carey, W. Huber and F. Hahne (2006). genefilter: methods for filtering genes from microarray experiments. R package version 1.13.7.
See Also
Examples
set.seed(123)
af <- oneWayAnova(c(rep(1,5),rep(2,5)))
af(rnorm(10))