gen.apply: Generate data for a set of models and contexts

Description Usage Arguments Value Author(s) See Also Examples

Description

Generate data for a set of models and contexts

Usage

1
gen.apply(models, pars, multiply = TRUE, n = 1, progress = FALSE)

Arguments

pars

a context or a list of contexts

multiply

a boolean value indicates in which way should models and pars be matched. If TRUE, each of the models is matched with every contexts in pars. Otherwise, they are matched element-wise. if TRUE the generating process will be performed on every possible combination from models and pars, if FALSE each model will be matched with its respective context in the same order specified in models and pars, in other words, set multiply to FALSE will make gen.apply does the exact same thing to mapply(gen,models,pars)

n

number of runs for each generation

progress

a boolean value indicates if the generating steps should be printed or not.

model

a character string indicates which model governs the learning process.

Value

a matrix with each entry is a context or a list of contexts, depending on the format indicated by multiply

Author(s)

Hoang-Trieu Trinh, thtrieu@apcs.vn

See Also

gen, mapply, sapply

Examples

1
2
3
# Suppose p1 and p2 are two different contexts
dat.1 <- gen.apply(ALL.MODELS, list(p1, p2), multiply = TRUE, n = 5)
dat.2 <- gen.apply(ALL.MODELS, list(p1, p2), multiply = FALSE, n = 5)

thtrieu/edmsyn documentation built on May 31, 2019, 11:18 a.m.