mmctSampler-methods: Methods for class mmctSampler', Package 'simctest'

Description Usage Arguments Methods Examples

Description

Constructor for class 'mmctSampler'.

Usage

1
 mmctSampler(f, num, data=NULL)

Arguments

f

a function f(ind,n,data) which for every hypothesis ind[i] in vector "ind" returns n[i] new samples and returns the number of exceedances, where i=1...length(ind). The data stored in the data slot of class "mmctSampler" is also passed on to "f".

num

number of hypotheses.

data

additional slot for data.

Methods

mmctSampler(f, num, data)

returns object of type 'mmctSampler' (derived from class 'mmctSamplerGeneric').

Examples

1
2
  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));

simctest documentation built on Nov. 4, 2019, 5:08 p.m.