From 3b8e9797fc347dc6fd41e82de219e423534e54fc Mon Sep 17 00:00:00 2001 From: "Carl A. B. Pearson" Date: Thu, 2 Nov 2023 16:17:31 +0000 Subject: [PATCH] add derivatives in anticipation of new deriv capability --- R/trans-numeric.R | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/R/trans-numeric.R b/R/trans-numeric.R index bc2b6a61..164ec803 100644 --- a/R/trans-numeric.R +++ b/R/trans-numeric.R @@ -30,7 +30,13 @@ atanh_trans <- function() { #' @examples #' plot(asinh_trans(), xlim = c(-1e2, 1e2)) asinh_trans <- function() { - trans_new("asinh", asinh, inverse = sinh) + trans_new( + "asinh", + transform = asinh, + inverse = sinh, + d_transform = function(x) 1 / sqrt(x^2 + 1), + d_inverse = cosh + ) } #' Box-Cox & modulus transformations