dep.oneway.second: A one-way design with dependent samples using published work:...

Description Usage Arguments Details Value Author(s) References See Also Examples

Description

dep.oneway.second conducts a one-way design with dependent samples, namely one-way repeated-measures analysis of variance, using published work.

Usage

1
2
dep.oneway.second(m, sd, n, corr, 
            unbiased = TRUE, contr = NULL, sig.level = 0.05, digits = 3)

Arguments

m

a numeric vector contains the means (length(m) >= 2)

sd

a numeric vector contains the sample/unbiased standard deviations (length(sd) >= 2)

n

a numeric contains the sample size (length(n) >= 2)

corr

a matrix or data frame contains the correlation matrix

unbiased

sd contains unbiased standard deviations (unbiased = TRUE, default) or sample standard deviations (unbiased = FALSE)

contr

a matrix or vector contains the contrast weights

sig.level

a numeric contains the significance level (default 0.05)

digits

the specified number of decimal places (default 3)

Details

This function conducts a one-way design with dependent samples, namely one-way repeated-measures analysis of variance, using published work. If you do not specify contr, all possible pairwise contrasts will be calculated.

Value

The returned object of dep.oneway.second contains the following components:

anova.table

returns a ANOVA table containing sums of squares, degrees of freedom, mean squares, F values, and a p value

omnibus.es

returns a omnibus effect size which is a partial η^2

raw.contrasts

returns raw mean differences, their confidence intervals, and standard errors

standardized.contrasts

returns standardized mean differences for the contrasts (Hedges's g) and their approximate confidence intervals for population standardized mean differences

Author(s)

Yasuyuki Okumura
Department of Social Psychiatry,
National Institute of Mental Health,
National Center of Neurology and Psychiatry
yokumura@blue.zero.jp

References

Kline RB (2004) Beyond significance testing: Reforming data analysis methods in behavioral research. Washington: American Psychological Association.

See Also

dep.oneway, lower2R

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
 
##Kline (2004) Table 6.3
dat <- data.frame(y = c(9,12,13,15,16,
                       8,12,11,10,14,
                       10,11,13,11,15),
                  x =  rep(factor(c("a","b","c")), each=5),
                  subj = rep(paste("s", 1:5, sep=""), times=3)
                  )
dep.oneway(formula = y~x, data=dat, block="subj")

datwide <- reshape(dat, direction="wide", idvar="subj", timevar="x")
tmp <- datwide[,-1]
dep.oneway.second(m = apply(tmp, 2, mean), apply(tmp, 2, sd), n = nrow(tmp), corr=cor(tmp))



##Kline (2004) Table 6.15
my.cont <- matrix(c(-5,-3,-1,1,3,5,
                   5,-1,-4,-4,-1,5), ncol=6, nrow=2, byrow=TRUE)
dep.oneway.second(m = c(11.77,21.39,27.5,31.02,32.58,34.2), 
                  sd = c(7.6,8.44,8.95,9.21,9.49,9.62), 
                  n = 137, 
                  corr=lower2R(c(.77,.59,.50,.48,.46,.81,.72,.69,.68,.89,
                  .84,.8,.91,.88,.93)),
                  contr=my.cont)

rpsychi documentation built on May 1, 2019, 10:10 p.m.