mmctSampler-class | R Documentation |
Wrapper-Class for "mmctestInterfaceGeneric", takes a function, the number of hypotheses and returns derived object of class "mmctestInterfaceGeneric". Class provides a slot for additional data. The function f(ind,n,data) has to return n[i] new samples for each hypothesis ind[i] in vector "ind", where i=1...length(ind). The data stored in the data slot of class "mmctSampler" is also passed on to "f".
Objects can be created by calls of the form mmctSampler(f=...,num=...,data=...)
.
f
:Object of class "function"
num
:Object of class "numeric"
data
:Object of class "numeric"
signature(obj="mmctSampler", ind="numeric", n="numeric")
: ...
signature(obj="mmctSampler")
: ...
Axel Gandy and Georg Hahn
Gandy, A. and Hahn, G. (2014) MMCTest - a safe algorithm for implementing multiple Monte Carlo tests. Scandinavian Journal of Statistics, 41(4):1083–1101
fun <- function(ind,n,data) sapply(1:length(ind), function(i) sum(runif(n[i])<=data[ind[i]]));
i <- mmctSampler(fun,num=500,data=runif(500));
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.