Running ‘testthat.R’
Running the tests in ‘tests/testthat.R’ failed.
Complete output:
  > library(testthat)
  > library(simukde)
  > 
  > test_check("simukde")
  ══ Skipped tests ═══════════════════════════════════════════════════════════════
  • Please run some tests manually for parallel computing. (1)
  
  ══ Failed tests ════════════════════════════════════════════════════════════════
  ── Error (test-simulate_kde.R:29:3): multivariate distribution ─────────────────
  Error in `linbin(x, gpoints, truncate)`: 'list' object cannot be coerced to type 'double'
  Backtrace:
       █
    1. ├─testthat::expect_silent(res <- simulate_kde(x = X, n = N)) test-simulate_kde.R:29:2
    2. │ └─testthat:::quasi_capture(enquo(object), NULL, evaluate_promise)
    3. │   ├─testthat:::.capture(...)
    4. │   │ ├─withr::with_output_sink(...)
    5. │   │ │ └─base::force(code)
    6. │   │ ├─base::withCallingHandlers(...)
    7. │   │ └─base::withVisible(code)
    8. │   └─rlang::eval_bare(quo_get_expr(.quo), quo_get_env(.quo))
    9. └─simukde::simulate_kde(x = X, n = N)
   10.   └─ks::kde(x = x, ...)
   11.     └─ks::hpi(...)
   12.       └─KernSmooth::dpik(x = x, level = nstage, gridsize = bgridsize)
   13.         └─KernSmooth:::linbin(x, gpoints, truncate)
  ── Error (test-simulate_kde.R:56:3): multivariate distribution ─────────────────
  Error in `linbin(x, gpoints, truncate)`: 'list' object cannot be coerced to type 'double'
  Backtrace:
       █
    1. ├─testthat::expect_silent(res <- simulate_kde(x = X, n = N, distr = "norm")) test-simulate_kde.R:56:2
    2. │ └─testthat:::quasi_capture(enquo(object), NULL, evaluate_promise)
    3. │   ├─testthat:::.capture(...)
    4. │   │ ├─withr::with_output_sink(...)
    5. │   │ │ └─base::force(code)
    6. │   │ ├─base::withCallingHandlers(...)
    7. │   │ └─base::withVisible(code)
    8. │   └─rlang::eval_bare(quo_get_expr(.quo), quo_get_env(.quo))
    9. └─simukde::simulate_kde(x = X, n = N, distr = "norm")
   10.   └─ks::kde(x = x, ...)
   11.     └─ks::hpi(...)
   12.       └─KernSmooth::dpik(x = x, level = nstage, gridsize = bgridsize)
   13.         └─KernSmooth:::linbin(x, gpoints, truncate)
  ── Error (test-simulate_kde.R:83:3): multivariate distribution ─────────────────
  Error in `linbin(x, gpoints, truncate)`: 'list' object cannot be coerced to type 'double'
  Backtrace:
      █
   1. ├─testthat::expect_is(...) test-simulate_kde.R:83:2
   2. │ └─testthat::quasi_label(enquo(object), label, arg = "object")
   3. │   └─rlang::eval_bare(expr, quo_get_env(quo))
   4. └─simukde::simulate_kde(x = X, const.only = TRUE)
   5.   └─ks::kde(x = x, ...)
   6.     └─ks::hpi(...)
   7.       └─KernSmooth::dpik(x = x, level = nstage, gridsize = bgridsize)
   8.         └─KernSmooth:::linbin(x, gpoints, truncate)
  
  [ FAIL 3 | WARN 0 | SKIP 1 | PASS 50 ]
  Error: Test failures
  Execution halted