Learn R Programming

INLAvaan (version 0.2.3)

dsnorm: The Skew Normal Distribution

Description

Density for the skew normal distribution with location xi, scale omega, and shape alpha.

Usage

dsnorm(x, xi, omega, alpha, logC = 0, log = FALSE)

Value

A numeric vector of (log) density values.

Arguments

x

Vector of quantiles.

xi

Location parameter.

omega

Scale parameter.

alpha

Shape parameter.

logC

Log-normalization constant.

log

Logical; if TRUE, returns the log density.

References

https://en.wikipedia.org/wiki/Skew_normal_distribution

Examples

Run this code
x <- seq(-2, 5, length.out = 100)
y <- dsnorm(x, xi = 0, omega = 1, alpha = 5)
plot(x, y, type = "l", main = "Skew Normal Density")

Run the code above in your browser using DataLab