checkPar {kergp}R Documentation

Check Length and Names of a Vector of Values for Parameters or Bounds

Description

Check length/names for a vector of values for parameters or bounds.

Usage

checkPar(value, parN, parNames, default)

Arguments

value

Numeric vector of values.

parN

Number of wanted values.

parNames

character. Names of the wanted values.

default

numeric. Default value.

Value

A numeric vector.

Examples

checkPar(value = c(1, 2), parN = 2L, parNames = c("theta", "sigma2"),
         default = 1.0)
checkPar(value = NULL, parN = 2L, parNames = c("theta", "sigma2"),
         default = 1.0)
checkPar(value = c("sigma2" = 100, "theta" = 1),
         parN = 2L, parNames = c("theta", "sigma2"),
         default = 1.0)


[Package kergp version 0.5.7 Index]