plot_lognormalvar: Plots a lognormal variable

Description Usage Arguments Value Author(s) See Also Examples

View source: R/report_auxiliary.R

Description

Plots the probability distribution function of a lognormal variable from the mean and standard deviation in either transformed (normal) or untransformed space.

Usage

1
plot_lognormalvar(m, sd, label = NULL, logtransform = FALSE, color = "black")

Arguments

m

A vector of means of the distribution.

sd

A vector of standard deviations of the distribution.

label

Name of the variable to be used as x-axis label.

logtransform

Indicates whether the mean and standard deviation are in transformed (normal) or untransformed space.

color

A vector of colors.

Value

A plot of the probability distribution function. Vertical dotted line indicates mean of distribution. This function can plot multiple curves when multiple means and standard deviations are provided.

Author(s)

Q. Huynh

See Also

plot_betavar plot_steepness

Examples

1
2
3
4
5
6
7
8
mu <- 0.5
stddev <- 0.1
plot_lognormalvar(mu, stddev) # mean of plot should be 0.5

#logtransformed parameters
mu <- 0
stddev <- 0.1
plot_lognormalvar(mu, stddev, logtransform = TRUE) # mean of plot should be 1

tcarruth/MSEtool documentation built on Sept. 16, 2020, 5:59 a.m.