calcpdf_mv: Log density of multivariate normal, lognormal, or product of...

Description Usage Arguments Value Author(s) See Also

View source: R/calcpdf_mv.R

Description

Calculate the logarithm of the probability density function of a multivariate normal or lognormal distribution, or of a product of independent one-dimensional distributions.

Usage

1
2
calcpdf_mv(z,dist="normal",mean=0,sd=1,cor=0,cor.inv=NA,log=TRUE,
           distdef=NA,file=NA)

Arguments

z

vector, matrix or data frame at which the logarithm of the probability density function will be evaluated

dist

distribution type: "Normal", "Lognormal", or "Indep"

mean

vector of means

sd

vector of standard deviations

cor

correlation matrix of the distribution

cor.inv

inverse of correlation matrix of the distribution (alternative input to cor, saves computation time for repeated calls)

log

if TRUE returns log of pdf, otherwise pdf

distdef

distribution definition for independent one-dimensional distributions

file

optional file to save results

Value

Probability density (or log density) at the sample points in z.

Author(s)

Peter Reichert <peter.reichert@eawag.ch>

See Also

calcpdf


baccione-eawag/EawagSchoolTools documentation built on Dec. 19, 2021, 6:38 a.m.