Learn R Programming

missDeaths (version 2.8)

md.mvnorm: md.mvnorm

Description

Creates information of a vector of multi-normal covariates with the specified array of means and covariance matrix. This function call must be added to the md.simparams object.

Usage

md.mvnorm(names, means = rep(0, length(names)), cov = diag(ncol(names)))

Arguments

names

vector of covariate names

means

vector of means, default is rep(0, length(names))

cov

covariance matrix, default is diag(ncol(names))

Examples

Run this code

if (FALSE) {
library(missDeaths)

sim = md.simparams() +
   md.mvnorm(c("X1", "X2"), c(100, 0), matrix(c(225, 3, 2, 1), 2, 2))
}

Run the code above in your browser using DataLab