returnCutoffValue(numberOfgroups, sample.size, targetalpha=0.05, MC.Method=TRUE, Table.Method=FALSE, Bayes.Method=FALSE, num.mc=1000, delta=0.05, nsims=200, v.threshold=NA)
The 'numberOfgroups' is a scalar denoting the number of groups or datasets being tested. The 'sample.size' should be a vector of length equal to the 'numberOfgroups' where sample.size[1] is the number of observations for group 1, sample.size[2] is the number of observations for group 2, etc. If only a single 'sample.size' is specified, it is assumed groups are of equal length.
MC.Method, Table.Method, and Bayes.Method are binary options. When MC.Method is TRUE, the cutoff is determined from a Monte-Carlo simulation where the number of resamplings is controlled by 'num.mc'. When Table.Method is TRUE, the cutoff is determined by imputation from a stored table of test statistics and significance levels for common sample sizes. When Bayes.Method is TRUE, the cutoff is determined through a Bayesian approach where the number of additional observations is controlled by nsims, and the threshold for acceptance is controlled by 'v.threshold'. See [Tsai 2013] for more details on the algorithm
The 'delta' value must be in the range [0,1]. Essentially this setting controls the range over which a minimum is taken to produce the EL ratio test statistic. The range is from 1 to n^(1-'delta') where 'n' represents the number of observations in 'x'.
returnCutoffValue(3, c(10,15,40), MC.Method=TRUE)
returnCutoffValue(3, c(10,15,40), MC.Method=TRUE, Bayes.Method=TRUE, Table.Method=TRUE)
Run the code above in your browser using DataLab