print.n.for.2means: Print n.for.2means results

Description Usage Arguments Author(s) See Also Examples

View source: R/epiDisplay.R

Description

Print results for sample size for hypothesis testing of 2 means

Usage

1
2
## S3 method for class 'n.for.2means'
print(x, ...)

Arguments

x

object of class 'n.for.2means'

...

further arguments passed to or used by methods.

Author(s)

Virasakdi Chongsuvivatwong <[email protected]>

See Also

'n.for.2p'

Examples

1
2
3
n.for.2means(mu1 = 10, mu2 = 14, sd1=3, sd2=3.5)
n.for.2means(mu1 = 10, mu2 = 7:14, sd1=3, sd2=3.5) -> a
a

Example output

Loading required package: foreign
Loading required package: survival
Loading required package: MASS
Loading required package: nnet

Estimation of sample size for testing Ho: mu1==mu2 
Assumptions: 
 
     alpha = 0.05 
     power = 0.8 
     n2/n1 = 1 
       mu1 = 10 
       mu2 = 14 
       sd1 = 3 
       sd2 = 3.5 
 
Estimated required sample size: 
 
        n1 = 11 
        n2 = 11 
   n1 + n2 = 22 
 

Estimation of sample size for testing Ho: mu1==mu2 
Assumptions: 
 
     alpha = 0.05 
     power = 0.8 
     n2/n1 = 1 

  mu1 mu2 sd1 sd2  n1  n2
1  10   7   3 3.5  19  19
2  10   8   3 3.5  42  42
3  10   9   3 3.5 167 167
4  10  10   3 3.5 Inf Inf
5  10  11   3 3.5 167 167
6  10  12   3 3.5  42  42
7  10  13   3 3.5  19  19
8  10  14   3 3.5  10  10

epiDisplay documentation built on May 11, 2018, 1:04 a.m.