glmmSimData: Simulation of data from a generalized linear mixed model.

Description Usage Arguments Author(s) References Examples

View source: R/glmmSimData.r

Description

Section 4.1.2 of the refence below descries a simulation study with data generated from a probit mixed model with six fixed effects parameters and a bivariate random effects vector having a 2 by 2 symmetric positive definite covariance matrix. The function simulates a data set from this model with 2500 groups and the number of observation in each group being a random draw from 20,21,...,30.

Usage

1
glmmSimData(seed=12345)

Arguments

seed

A positive integer which acts the seed for random data generation.

Author(s)

Matt Wandmatt.wand@uts.edu.au and James Yujames.yu@student.uts.edu.au

References

Hall, P.,Johnstone, I.M., Ormerod, J.T., Wand, M.P. and Yu, J. (2018). Fast and accurate binary response mixed model analysis via expectation propagation. <arXiv:1805.08423v1>.

Examples

1
2
3
4
5
6
# Obtain simulated data corresponding to the simulation study in Section 4.1.2. of 
# Hall et al. (2018):

library(glmmEP)
dataObj <- glmmSimData(seed=54321)
print(names(dataObj))

Example output

glmmEP 1.0 loaded.
Copyright M.P. Wand and J.C.F. Yu 2019.
For details on the use of glmmEP, issue the command:
glmmEPvignette()
[1] "y"       "Xfixed"  "Xrandom" "idNum"  

glmmEP documentation built on Oct. 30, 2019, 9:39 a.m.