seq_mr_smd: seq_mr_smd

View source: R/seq_mr_smd.R

seq_mr_smdR Documentation

seq_mr_smd

Description

Purely Sequential approach to Get Minimum Risk Point Estimation for the Standardized Mean Difference

Usage

seq_mr_smd(
  data1,
  data2,
  A,
  c1,
  c2,
  gamma,
  verbose = FALSE,
  pilot = FALSE,
  na.rm = TRUE
)

Arguments

data1

The first data vector for which to calculate the minimum risk point.

data2

The second data vector for which to calculate the minimum risk point.

A

The loss function constant.

c1

The cost of unit sample for the first data vector.

c2

The cost of unit sample for the second data vector.

gamma

gamma

verbose

Should the criterion be printed. Default is FALSE.

pilot

Should a pilot sample be generated. TRUE/FALSE value. default value is FALSE.

na.rm

This parameter controls whether NA values are removed from the data prior to calculation. Default is TRUE.

Value

The calculated minimum risk point, the sample size of each data vector, the mean of each vector, and an indicator of if the criterion is satisfied.

Author(s)

Ken Kelley KKelley@nd.edu, Bhargab Chattopadhyay Bhargab@iiitvadodara.ac.in, Neetu Shah 201451015@iiitvadodara.ac.in

Bhargab Chattopadhyay Bhargab@iiitvadodara.ac.in, Ken Kelley kkelley@nd.edu

References

Chattopadhyay, B., & Kelley, K. (2017). Estimating the standardized mean difference with minimum risk: Maximizing accuracy and minimizing cost with sequential estimation. Psychological Methods, 22(1), 94-113

Examples

pilot_ss <- seq_mr_smd(gamma=1, A=100, c1=4, c2=5, pilot=TRUE)
SLS1 <- rnorm(pilot_ss[1], mean=0, sd=1)
SLS2 <- rnorm(pilot_ss[2], mean=0, sd=1)
seq_mr_smd(data1=SLS1, data2=SLS2, A=100, c1=4, c2=5, pilot=FALSE)

yelleKneK/SMSD documentation built on Nov. 23, 2022, 6:40 p.m.