Nothing
#' Variance of Asymmetric Laplace random variables
#'
#' Compute the variance for the asymmetric Laplace Distribution.
#'
#' @param sigma scale parameter
#' @param qtl skewness parameter
#'
#' @return Return the variance of Asymmetric Laplace random variables for given scale (\code{sigma}) and skewness (\code{qtl}) parameters.
#'
#' @references{
#' \insertRef{ref:dal1}{lqmix}
#' }
#' @references{
#' \insertRef{ref:dal2}{lqmix}
#' }
#'
#' @references{
#' \insertRef{ref:dal3}{lqmix}
#' }
#' @export
varAL = function (sigma, qtl){
eps <- .Machine$double.eps^(2/3)
if (qtl > 1 | qtl < 0) stop("Parameter 'qtl' must be in [0,1]")
if (qtl == 0) qtl = eps
if (qtl == 1) qtl = 1 - eps
if (sigma < 0) warning("Scale parameter 'sigma' is negative")
sigma^2 * (1 - 2 * qtl + 2 * qtl^2)/((1 - qtl)^2 * qtl^2)
}
Any scripts or data that you put into this service are public.
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.