correlation_function: Generate Matern covariance matrix

View source: R/correlation-function.R

correlation_functionR Documentation

Generate Matern covariance matrix

Description

A function for generating the Matern covariance matrix

Usage

correlation_function(D, theta, corr_fun = "exponential")

Arguments

D

is an n x n matrix of pairwise distances between locations

theta

is the correlation function parameters. If corr_fun is "matern", then theta is a 2-dimensional vector of Matern covariance parameter inputs on the log-scale with the first element the Matern range parameter range on the log-scale and second element the Matern smoothness parameter nu on the log-scale. If corr_fun is "exponential" then theta is a positive number representing the exponential correlation function range parameter on the log-scale.

corr_fun

is the correlation function


jtipton25/pgR documentation built on July 8, 2022, 12:44 a.m.