Running ‘testthat.R’ [11s/17s]
Running the tests in ‘tests/testthat.R’ failed.
Complete output:
  > library(testthat)
  > library(haldensify)
  haldensify v0.2.3: Highly Adaptive Lasso Conditional Density Estimation
  > 
  > test_check("haldensify")
  [ FAIL 5 | WARN 0 | SKIP 0 | PASS 0 ]
  
  ══ Failed tests ════════════════════════════════════════════════════════════════
  ── Error ('test-density_marginal.R:19:1'): (code run outside of `test_that()`) ──
  Error in `.local(x, y, ...)`: non-conformable arguments
  Backtrace:
       ▆
    1. ├─stats::predict(...) at test-density_marginal.R:19:1
    2. └─haldensify:::predict.haldensify(...)
    3.   ├─stats::predict(...)
    4.   └─hal9001:::predict.hal9001(...)
    5.     └─base::apply(...)
    6.       └─hal9001 (local) FUN(newX[, i], ...)
    7.         ├─base::as.vector(...)
    8.         ├─Matrix::tcrossprod(x = pred_x_basis, y = hal_coefs[-1])
    9.         └─Matrix::tcrossprod(x = pred_x_basis, y = hal_coefs[-1])
   10.           └─Matrix (local) .local(x, y, ...)
  ── Error ('test-density_standard.R:23:1'): (code run outside of `test_that()`) ──
  Error in `.local(x, y, ...)`: non-conformable arguments
  Backtrace:
       ▆
    1. ├─stats::predict(haldensify_fit, new_A = new_dat$a, new_W = new_dat$w_neg) at test-density_standard.R:23:1
    2. └─haldensify:::predict.haldensify(...)
    3.   ├─stats::predict(...)
    4.   └─hal9001:::predict.hal9001(...)
    5.     └─base::apply(...)
    6.       └─hal9001 (local) FUN(newX[, i], ...)
    7.         ├─base::as.vector(...)
    8.         ├─Matrix::tcrossprod(x = pred_x_basis, y = hal_coefs[-1])
    9.         └─Matrix::tcrossprod(x = pred_x_basis, y = hal_coefs[-1])
   10.           └─Matrix (local) .local(x, y, ...)
  ── Error ('test-density_weights.R:38:1'): (code run outside of `test_that()`) ──
  Error in `.local(x, y, ...)`: non-conformable arguments
  Backtrace:
       ▆
    1. ├─stats::predict(...) at test-density_weights.R:38:1
    2. └─haldensify:::predict.haldensify(...)
    3.   ├─stats::predict(...)
    4.   └─hal9001:::predict.hal9001(...)
    5.     └─base::apply(...)
    6.       └─hal9001 (local) FUN(newX[, i], ...)
    7.         ├─base::as.vector(...)
    8.         ├─Matrix::tcrossprod(x = pred_x_basis, y = hal_coefs[-1])
    9.         └─Matrix::tcrossprod(x = pred_x_basis, y = hal_coefs[-1])
   10.           └─Matrix (local) .local(x, y, ...)
  ── Error ('test-ipw_est.R:16:1'): (code run outside of `test_that()`) ──────────
  Error in `.local(x, y, ...)`: non-conformable arguments
  Backtrace:
       ▆
    1. └─haldensify::ipw_shift(...) at test-ipw_est.R:16:1
    2.   ├─stats::predict(...)
    3.   └─haldensify:::predict.haldensify(...)
    4.     ├─stats::predict(...)
    5.     └─hal9001:::predict.hal9001(...)
    6.       └─base::apply(...)
    7.         └─hal9001 (local) FUN(newX[, i], ...)
    8.           ├─base::as.vector(...)
    9.           ├─Matrix::tcrossprod(x = pred_x_basis, y = hal_coefs[-1])
   10.           └─Matrix::tcrossprod(x = pred_x_basis, y = hal_coefs[-1])
   11.             └─Matrix (local) .local(x, y, ...)
  ── Error ('test-ratio_covar.R:19:1'): (code run outside of `test_that()`) ──────
  Error in `.local(x, y, ...)`: non-conformable arguments
  Backtrace:
       ▆
    1. ├─stats::predict(...) at test-ratio_covar.R:19:1
    2. └─haldensify:::predict.haldensify(...)
    3.   ├─stats::predict(...)
    4.   └─hal9001:::predict.hal9001(...)
    5.     └─base::apply(...)
    6.       └─hal9001 (local) FUN(newX[, i], ...)
    7.         ├─base::as.vector(...)
    8.         ├─Matrix::tcrossprod(x = pred_x_basis, y = hal_coefs[-1])
    9.         └─Matrix::tcrossprod(x = pred_x_basis, y = hal_coefs[-1])
   10.           └─Matrix (local) .local(x, y, ...)
  
  [ FAIL 5 | WARN 0 | SKIP 0 | PASS 0 ]
  Error: Test failures
  Execution halted