Learn R Programming

BayesTools (version 0.2.18)

mean.prior: Prior mean

Description

Computes mean of a prior distribution. (In case of orthonormal prior distributions for factors, the mean of for the deviations from intercept is returned.)

Usage

# S3 method for prior
mean(x, ...)

Value

a mean of an object of class 'prior'.

Arguments

x

a prior

...

unused

See Also

prior()

Examples

Run this code
# create a standard normal prior distribution
p1 <- prior(distribution = "normal", parameters = list(mean = 1, sd = 1))

# compute mean of the prior distribution
mean(p1)

Run the code above in your browser using DataLab