Learn R Programming

graphicalExtremes (version 0.2.0)

par2Matrix: Create Gamma or Theta from vector

Description

This function takes the parameters in the vector par (upper triangular Gamma/Theta matrix) and returns the full Gamma/Theta.

Usage

par2Matrix(par, allowMatrix = FALSE, allowNull = FALSE, zeroRowSums = FALSE)

par2Gamma(par, allowMatrix = FALSE, allowNull = FALSE)

par2Theta(par, allowMatrix = FALSE, allowNull = FALSE)

Value

Numeric matrix \(d \times d\). Full Gamma/Theta matrix.

Arguments

par

Numeric vector with d elements. Upper triangular part of a Gamma/Theta matrix.

allowMatrix

If TRUE and par is already a matrix, return it as is.

allowNull

If TRUE and par is NULL, return NULL.

zeroRowSums

If TRUE the diagonal is set to (-1) times the rowSums.