From fac4f8c2e01cb3c346705a02263915d4d07ffd7b Mon Sep 17 00:00:00 2001 From: n-kall Date: Wed, 10 Jan 2024 16:03:31 +0200 Subject: [PATCH] fix pareto smoothing weights test --- tests/testthat/test-pareto_smooth.R | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tests/testthat/test-pareto_smooth.R b/tests/testthat/test-pareto_smooth.R index 9994d3df..89635600 100644 --- a/tests/testthat/test-pareto_smooth.R +++ b/tests/testthat/test-pareto_smooth.R @@ -198,7 +198,7 @@ test_that("pareto_smooth works for log_weights", { ps <- pareto_smooth(lw, are_log_weights = TRUE, verbose = FALSE, ndraws_tail = 10, return_k = TRUE) # only right tail is smoothed - expect_equal(ps$x[1:15], lw[1:15]) + expect_equal(ps$x[1:15] + max(lw), lw[1:15]) expect_true(ps$diagnostics$khat > 0.7)