R/dst_cauchy.R

Defines functions dst_cauchy

Documented in dst_cauchy

#' Cauchy Distribution
#'
#' Makes a distribution belonging to the family of
#' cauchy distributions.
#'
#' @param location Location parameter
#' @param scale positive
#'
#' @examples
#' dst_cauchy(0, 1)
#'
#'@export
dst_cauchy <- function(location, scale){
  if (scale <= 0){
    stop('Scale must be positive')
  }
  dst_parametric(
    "cauchy", location = location, scale = scale,
    .variable = "continuous", .env = "package:stats"
  )
}
vincenzocoia/distionary documentation built on March 5, 2024, 3:13 a.m.