powered by
Random values of bias and interaction parameters are generated using either uniform or normal distributions.
randompar(predictors, distr = "unif", h0 = 0, dh = 1, J0 = 0, dJ = 1)
List of predictor factor levels. See bbl.
bbl
c('unif','norm') for uniform or normal distributions.
c('unif','norm')
Mean of bias parameters
sd of bias if distr = 'unif'. If distr = 'norm', \(h = [h_0-dh, h_0+dh]\).
sd
distr = 'unif'
distr = 'norm'
Mean of interaction parameters.
sd of interactions if distr = 'unif'. If distr = 'norm', \(J = [J_0-dJ, J_0+dJ]\).
List of parameters, h and J.
h
J
Input argument predictors is used to set up proper list structures of parameters.
predictors
# NOT RUN { set.seed(311) predictors <- list() for(i in 1:5) predictors[[i]] <- c('a','c') par <- randompar(predictors=predictors) par # }
Run the code above in your browser using DataLab