diff --git a/R/deprecated.R b/R/deprecated.R index f168c89411dfc3c2d14dd4b1a6a5273ebfd798c1..9893af4525f8df0b334f726cb265c9db4d4dd862 100644 --- a/R/deprecated.R +++ b/R/deprecated.R @@ -4,9 +4,6 @@ #' `r lifecycle::badge("deprecated")` #' #' Use [dmcd()] instead of `mvdcd()`. -#' Use [rmcd()] instead of `mvrcd()`. -#' Use [plotmcd()] instead of `plotmvcd()`. -#' Use [contourmcd()] instead of `contourmvcd()`. #' #' @importFrom lifecycle deprecate_soft #' @export @@ -19,12 +16,27 @@ mvdcd <- function(x, mu, Sigma, tol = 1e-6) { dmcd(x, mu, Sigma, tol) } +#' @description +#' Use [rmcd()] instead of `mvrcd()`. +#' +#' @importFrom lifecycle deprecate_soft +#' @export +#' @keywords internal +#' @rdname deprecated mvrcd <- function(n, mu, Sigma, tol = 1e-6) { deprecate_soft("1.2.0", "mvrcd()", "rmcd()") rmcd(n, mu, Sigma, tol) } +#' @description +#' Use [plotmcd()] instead of `plotmvcd()`. +#' Use [contourmcd()] instead of `contourmvcd()`. +#' +#' @importFrom lifecycle deprecate_soft +#' @export +#' @keywords internal +#' @rdname deprecated plotmvcd <- function(mu, Sigma, xlim = c(mu[1] + c(-10, 10)*Sigma[1, 1]), ylim = c(mu[2] + c(-10, 10)*Sigma[2, 2]), n = 101, xvals = NULL, yvals = NULL, xlab = "x", ylab = "y", @@ -35,6 +47,13 @@ plotmvcd <- function(mu, Sigma, xlim = c(mu[1] + c(-10, 10)*Sigma[1, 1]), col, tol, ...) } +#' @description +#' Use [contourmcd()] instead of `contourmvcd()`. +#' +#' @importFrom lifecycle deprecate_soft +#' @export +#' @keywords internal +#' @rdname deprecated contourmvcd <- function(mu, Sigma, beta, xlim = c(mu[1] + c(-10, 10)*Sigma[1, 1]), ylim = c(mu[2] + c(-10, 10)*Sigma[2, 2]), diff --git a/man/deprecated.Rd b/man/deprecated.Rd index 47e469d968aae25d82af11ac534875202f027d70..cca8332f30096703434e680bdaee27dced8ceb6c 100644 --- a/man/deprecated.Rd +++ b/man/deprecated.Rd @@ -3,16 +3,59 @@ \name{deprecated} \alias{deprecated} \alias{mvdcd} +\alias{mvrcd} +\alias{plotmvcd} +\alias{contourmvcd} \title{Deprecated functions} \usage{ mvdcd(x, mu, Sigma, tol = 1e-06) + +mvrcd(n, mu, Sigma, tol = 1e-06) + +plotmvcd( + mu, + Sigma, + xlim = c(mu[1] + c(-10, 10) * Sigma[1, 1]), + ylim = c(mu[2] + c(-10, 10) * Sigma[2, 2]), + n = 101, + xvals = NULL, + yvals = NULL, + xlab = "x", + ylab = "y", + zlab = "f(x,y)", + col = "gray", + tol = 1e-06, + ... +) + +contourmvcd( + mu, + Sigma, + beta, + xlim = c(mu[1] + c(-10, 10) * Sigma[1, 1]), + ylim = c(mu[2] + c(-10, 10) * Sigma[2, 2]), + zlim = NULL, + npt = 30, + nx = npt, + ny = npt, + main = "Multivariate generalised Gaussian density", + sub = NULL, + nlevels = 10, + levels = pretty(zlim, nlevels), + tol = 1e-06, + ... +) } \description{ \ifelse{html}{\href{https://lifecycle.r-lib.org/articles/stages.html#deprecated}{\figure{lifecycle-deprecated.svg}{options: alt='[Deprecated]'}}}{\strong{[Deprecated]}} Use \code{\link[=dmcd]{dmcd()}} instead of \code{mvdcd()}. + Use \code{\link[=rmcd]{rmcd()}} instead of \code{mvrcd()}. + Use \code{\link[=plotmcd]{plotmcd()}} instead of \code{plotmvcd()}. +Use \code{\link[=contourmcd]{contourmcd()}} instead of \code{contourmvcd()}. + Use \code{\link[=contourmcd]{contourmcd()}} instead of \code{contourmvcd()}. } \keyword{internal}