getCorMat: Create a correlation matrix.

Description Usage Arguments Details Value Examples

Description

getCorMat returns a correlation matrix.

Usage

1
getCorMat(x, rho)

Arguments

x

An n x d matrix.

rho

A vector of length d.

Details

This creates a correlation matrix, R, where

R_ij = ∏_{k = 1}^{d}ρ_k^{16≤ft( x_{ik} - x_{jk} \right)^2}

Value

An n x n correlation matrix

Examples

1
2
3
4
5
n <- 10
d <- 2
x <- matrix(runif(n * d), nrow = n, ncol = d)
rho <- runif(d, 0, 1)
getCorMat(x, rho)

cbdavis33/bcgp1 documentation built on May 6, 2019, 6:57 p.m.