lognormal: Construct a log-normal distribution object.

View source: R/lognormal.R

lognormalR Documentation

Construct a log-normal distribution object.

Description

Creates an S3 object representing a log-normal distribution with the given meanlog and sdlog parameters. The log-normal PDF is

f(t) = \frac{1}{t \cdot sdlog \sqrt{2\pi}} \exp\!\left(-\frac{(\log t - meanlog)^2}{2 \cdot sdlog^2}\right)

for t > 0.

Usage

lognormal(meanlog = 0, sdlog = 1)

Arguments

meanlog

Mean of the distribution on the log scale (default 0).

sdlog

Standard deviation on the log scale (default 1), must be positive.

Value

A lognormal object with classes c("lognormal", "univariate_dist", "continuous_dist", "dist").

Examples

x <- lognormal(meanlog = 0, sdlog = 1)
mean(x)
vcov(x)
format(x)

algebraic.dist documentation built on Feb. 27, 2026, 5:06 p.m.