plotsl {sld}R Documentation

Plots of density and distribution function for the quantile based skew logistic distribution

Description

Produces plots of density and distribution function for the quantile based skew logistic distribution. Although you could use curve(dsl(x)) to do this, the fact that the density and quantiles of this distribution are defined in terms of the depth, u, means that a seperate function that uses the depths to produce the values to plot is more accurate and efficient.

Usage

plotsld(parameters, add=FALSE, granularity = 10000,
  xlab = "x", ylab="density", quant.probs = seq(0,1,.25), ...)
plotslc(parameters, add=FALSE, granularity = 10000,
  xlab = "quantile", ylab="depth", quant.probs = seq(0,1,.25), ...)

Arguments

parameters

A vector of length 3, giving the parameters of the quantile-based skew logistic distribution. The 3 elements are \alpha (location), \beta (scale) and \delta (skewing). \alpha can take on any real value, \beta can take on any positive value and \delta must satisfy 0 \leq \delta \leq 1. \delta = 0.5 gives the logistic distribution, \delta = 0 gives the reflected exponential distribution and \delta = 1 gives the exponential distribution.

add

Should this add to an existing plot (using lines) or produce a new plot (using plot).

granularity

Number of points at which quantiles and density will be calculated.— see details

xlab

X axis label

ylab

Y axis label

quant.probs

Quantiles of distribution to return (see value below). Set to NULL to suppress this return entirely.

...

arguments that get passed to plot if this is a new plot

Details

The quantile-based skew logistic distribution is defined by its quantile function. The density of the distribution is available explicitly as a function of depths, u, but not explicitly available as a function of x (except for the special cases at \delta=0,0.5 and 1). This function calculates quantiles and density as a function of depths to produce a density plot plotsld or cumulative probability plot plotslc.

Value

A number of quantiles from the distribution, the default being the minimum, maximum and quartiles.

Author(s)

Robert King, robert.king.newcastle@gmail.com, https://github.com/newystats/sld

References

van Staden, P.J. and King, Robert A.R. (2015) The quantile-based skew logistic distribution, Statistics and Probability Letters 96, 109–116. doi: 10.1016/j.spl.2014.09.001

van Staden, Paul J. 2013 Modeling of generalized families of probability distribution in the quantile statistical universe. PhD thesis, University of Pretoria. http://hdl.handle.net/2263/40265

https://github.com/newystats/sld

See Also

sld

Examples

plotsld(c(0,1,1),main="Exponential Distribution")
plotsld(c(0,1,0.5),main="Logistic Distribution")
plotsld(c(0,1,0.7))
plotslc(c(0,1,0.7))

[Package sld version 1.0.1 Index]