Learn R Programming

reproducer (version 0.4.2)

RandomizedBlockDesignEffectSizes: RandomizedBlockDesignEffectSizes

Description

This function finds the theoretical effect sizes for a four-group randomized block experiments assuming one of four different underlying distributions specified by the type parameter. The design assumes two blocks each comprising a control and treatment group. If required a fixed Blocking effect is added to the mean for Block 2.

Usage

RandomizedBlockDesignEffectSizes(
  m1,
  std1,
  m2,
  std2,
  m3,
  std3,
  m4,
  std4,
  BE = 0,
  type = "n"
)

Value

dataframe holing the expected unstandardized mean difference effect size, the pooled within group variance, the standardized effect size and the point bi-serial correlation.

Arguments

m1

The theoretical mean for the control group in Block 1

std1

The theoretical variance for the control group in Block 1

m2

The theoretical mean for the treatment group in Block 1

std2

The theoretical variance for the treatment group in Block 1

m3

The theoretical mean for the control group in Block 2

std3

The theoretical variance for the control group in Block 2

m4

The theoretical mean for the treatment group in Block 2

std4

The theoretical variance for the treatment group in Block 2

BE

A fixed block effect to be added to the Block 2 mean values.

type

String identifying the distribution, "n" for normal, "ln" for lognormal, "lap" for Laplace, "g" for Gamma

Author

Barbara Kitchenham and Lech Madeyski

Examples

Run this code
RandomizedBlockDesignEffectSizes(m1=0,std1=1,m2=1,std2=1,m3=0,std3=1,m4=1,std4=1,BE=1,type="n")
#  A tibble: 1 x 4
#      ES   Var StdES  rPBS
#      
# 1     1     1     1 0.447
RandomizedBlockDesignEffectSizes(m1=0,std1=1,m2=1,std2=1,m3=0,std3=1,m4=1,std4=1,BE=1,type="l")
#  A tibble: 1 x 4
#      ES   Var StdES  rPBS
#      
# 1  5.27  82.2 0.581 0.279
RandomizedBlockDesignEffectSizes(m1=0,std1=1,m2=0.266,std2=1,m3=0,std3=1,m4=0.266,std4=1,BE=0,
 type = "l")
#  A tibble: 1 x 4
#      ES   Var StdES   rPBS
#       
# 1 0.502  6.31 0.200 0.0995

Run the code above in your browser using DataLab