Skip to contents

Draw multivariate normal samples under a structured covariance

Usage

morie_mvn_with_covariance(
  n,
  p,
  rng,
  kernel = c("ar1", "independent", "compound", "toeplitz"),
  rho = 0.5,
  mean = NULL
)

Arguments

n

Number of samples.

p

Dimension.

rng

morie_sync_rng() environment.

kernel

One of "independent", "ar1", "compound", "toeplitz".

rho

Correlation parameter.

mean

Optional length-p mean vector.

Value

An n x p matrix of samples.

Examples

# See the package vignettes for usage examples:
#   vignette(package = "rmorie")