View source: R/withinBlockEffects.R
withinBlockEffects | R Documentation |
Calculates the differences of mean outcomes for multiple specified treatment factors and specified pairs of comparison levels, within the specified blocks.
withinBlockEffects(y, w, calcOptions)
y |
a vector or matrix of outcomes. |
w |
a vector or matrix of assignments. |
calcOptions |
a list of options for calculating the difference of mean outcomes within blocks.
|
calcOptions$block
should have the same length as y
and w
.
If unspecified, calcOptions$pairs
defaults to c(0,1)
.
If calcOptions$factors
is specified, its length must equal the number of rows specified in calcOptions$pairs
.
If unspecified, calcOptions$factors
defaults to an appropriately-sized vector of 1
's.
calcOptions$blockindex
should have the same length as calcOptions$factors
.
A vector of differences of mean outcomes within blocks.
Joseph J. Lee and Tirthankar Dasgupta
Moore, David S., and George P. McCabe (1989). Introduction to the Practice of Statistics. Original source: study conducted by Jim Baumann and Leah Jones of the Purdue University Education Department.
diffMeansVector
# Reading comprehension pre- and post-test example data(reading) withinBlockEffects( y = reading$Diff1, w = reading$Group, calcOptions = list( block = reading$Block, pairs = rbind( c("Basal", "DRTA"), c("Basal", "Strat"), c("DRTA", "Strat"), c("Basal", "DRTA"), c("Basal", "Strat"), c("DRTA", "Strat") ), blockindex = c(rep(1, 3), rep(2, 3)) ) )
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.