Last updated on 2026-10-27 05:58:30 CET.
| Flavor | Version | Tinstall | Tcheck | Ttotal | Status | Flags |
|---|---|---|---|---|---|---|
| r-devel-linux-x86_64-debian-clang | 1.0.0 | 2.40 | 64.77 | 67.17 | OK | |
| r-devel-linux-x86_64-debian-gcc | 1.0.0 | 1.83 | 37.76 | 39.59 | ERROR | |
| r-devel-linux-x86_64-fedora-clang | 1.0.0 | 36.06 | ERROR | |||
| r-devel-linux-x86_64-fedora-gcc | 1.0.0 | 38.02 | ERROR | |||
| r-devel-windows-x86_64 | 1.0.0 | 5.00 | 71.00 | 76.00 | ERROR | |
| r-patched-linux-x86_64 | 1.0.0 | 2.55 | 57.00 | 59.55 | OK | |
| r-release-linux-x86_64 | 1.0.0 | 2.16 | 42.26 | 44.42 | ERROR | |
| r-release-macos-arm64 | 1.0.0 | 1.00 | 22.00 | 23.00 | OK | |
| r-release-macos-x86_64 | 1.0.0 | 2.00 | 79.00 | 81.00 | OK | |
| r-release-windows-x86_64 | 1.0.0 | 4.00 | 81.00 | 85.00 | OK | |
| r-oldrel-macos-arm64 | 1.0.0 | OK | ||||
| r-oldrel-macos-x86_64 | 1.0.0 | 2.00 | 74.00 | 76.00 | OK | |
| r-oldrel-windows-x86_64 | 1.0.0 | 5.00 | 98.00 | 103.00 | OK |
Version: 1.0.0
Check: examples
Result: ERROR
Running examples in ‘steppedwedge-Ex.R’ failed
The error most likely occurred in:
> base::assign(".ptime", proc.time(), pos = "CheckExEnv")
> ### Name: analyze
> ### Title: Analyze a stepped wedge dataset
> ### Aliases: analyze
>
> ### ** Examples
>
> # Load data
> test_data <- load_data(time ="period", cluster_id = "cluster", individual_id = NULL,
+ treatment = "trt", outcome = "outcome_cont", data = sw_data_example)
Stepped wedge dataset loaded. Discrete time design with 15 clusters, 5 sequences, and 6 time points.
>
> # Analysis example 1: TATE estimand for exposure times 1 through 4
> results_tate <- analyze(dat = test_data, method = "mixed", estimand_type = "TATE",
+ estimand_time = c(1, 4), exp_time = "ETI")
Error in model.frame.default(data = dat, offset = offset, drop.unused.levels = TRUE, :
invalid type (closure) for variable '(offset)'
Calls: analyze ... mkFormula -> eval -> eval -> <Anonymous> -> model.frame.default
Execution halted
Flavors: r-devel-linux-x86_64-debian-gcc, r-release-linux-x86_64
Version: 1.0.0
Check: tests
Result: ERROR
Running ‘testthat.R’ [3s/4s]
Running the tests in ‘tests/testthat.R’ failed.
Complete output:
> # This file is part of the standard setup for testthat.
> # It is recommended that you do not modify it.
> #
> # Where should you do additional test configuration?
> # Learn more about the roles of various files in:
> # * https://r-pkgs.org/testing-design.html#sec-tests-files-overview
> # * https://testthat.r-lib.org/articles/special-files.html
>
> library(testthat)
> library(steppedwedge)
>
> test_check("steppedwedge")
Stepped wedge dataset loaded. Discrete time design with 2 clusters, 2 sequences, and 3 time points.
Saving _problems/test-analyze_data-33.R
Saving _problems/test-analyze_data-40.R
Saving _problems/test-analyze_data-47.R
Saving _problems/test-analyze_data-78.R
Saving _problems/test-analyze_data-88.R
Stepped wedge dataset loaded. Discrete time design with 2 clusters, 2 sequences, and 3 time points.
Stepped wedge dataset loaded. Discrete time design with 2 clusters, 2 sequences, and 3 time points.
[ FAIL 5 | WARN 0 | SKIP 0 | PASS 24 ]
══ Failed tests ════════════════════════════════════════════════════════════════
── Error ('test-analyze_data.R:32:3'): Correct model type and estimand_type for IT mixed model ──
Error in `model.frame.default(data = dat, offset = offset, drop.unused.levels = TRUE, formula = outcome ~ factor(time) - 1 + treatment + (1 + cluster_id) + (1 + ij))`: invalid type (closure) for variable '(offset)'
Backtrace:
▆
1. └─steppedwedge::analyze(...) at test-analyze_data.R:32:3
2. ├─lme4::lmer(formula, data = dat, offset = offset)
3. │ └─base::eval(mc, parent.frame(1L))
4. │ └─base::eval(mc, parent.frame(1L))
5. ├─lme4::lFormula(...)
6. │ └─lme4:::mkFormula(...)
7. │ └─base::eval(mf, parent_env)
8. │ └─base::eval(mf, parent_env)
9. ├─stats::model.frame(...)
10. └─stats::model.frame.default(...)
── Error ('test-analyze_data.R:39:3'): Correct model type and estimand_type for ETI mixed model, TATE ──
Error in `model.frame.default(data = dat, offset = offset, drop.unused.levels = TRUE, formula = outcome ~ factor(time) - 1 + factor(exposure_time) + (1 + cluster_id) + (1 + ij))`: invalid type (closure) for variable '(offset)'
Backtrace:
▆
1. └─steppedwedge::analyze(...) at test-analyze_data.R:39:3
2. ├─lme4::lmer(formula, data = dat, offset = offset)
3. │ └─base::eval(mc, parent.frame(1L))
4. │ └─base::eval(mc, parent.frame(1L))
5. ├─lme4::lFormula(...)
6. │ └─lme4:::mkFormula(...)
7. │ └─base::eval(mf, parent_env)
8. │ └─base::eval(mf, parent_env)
9. ├─stats::model.frame(...)
10. └─stats::model.frame.default(...)
── Error ('test-analyze_data.R:46:3'): Correct model type and estimand_type for ETI mixed model, PTE ──
Error in `model.frame.default(data = dat, offset = offset, drop.unused.levels = TRUE, formula = outcome ~ factor(time) - 1 + factor(exposure_time) + (1 + cluster_id) + (1 + ij))`: invalid type (closure) for variable '(offset)'
Backtrace:
▆
1. └─steppedwedge::analyze(...) at test-analyze_data.R:46:3
2. ├─lme4::lmer(formula, data = dat, offset = offset)
3. │ └─base::eval(mc, parent.frame(1L))
4. │ └─base::eval(mc, parent.frame(1L))
5. ├─lme4::lFormula(...)
6. │ └─lme4:::mkFormula(...)
7. │ └─base::eval(mf, parent_env)
8. │ └─base::eval(mf, parent_env)
9. ├─stats::model.frame(...)
10. └─stats::model.frame.default(...)
── Error ('test-analyze_data.R:77:3'): Model coefficients are returned correctly ──
Error in `model.frame.default(data = dat, offset = offset, drop.unused.levels = TRUE, formula = outcome ~ factor(time) - 1 + treatment + (1 + cluster_id) + (1 + ij))`: invalid type (closure) for variable '(offset)'
Backtrace:
▆
1. └─steppedwedge::analyze(...) at test-analyze_data.R:77:3
2. ├─lme4::lmer(formula, data = dat, offset = offset)
3. │ └─base::eval(mc, parent.frame(1L))
4. │ └─base::eval(mc, parent.frame(1L))
5. ├─lme4::lFormula(...)
6. │ └─lme4:::mkFormula(...)
7. │ └─base::eval(mf, parent_env)
8. │ └─base::eval(mf, parent_env)
9. ├─stats::model.frame(...)
10. └─stats::model.frame.default(...)
── Error ('test-analyze_data.R:87:3'): Function handles different family and link functions ──
Error in `model.frame.default(data = dat, offset = offset, drop.unused.levels = TRUE, formula = outcome ~ factor(time) - 1 + treatment + (1 + cluster_id) + (1 + ij))`: invalid type (closure) for variable '(offset)'
Backtrace:
▆
1. └─steppedwedge::analyze(...) at test-analyze_data.R:87:3
2. ├─lme4::glmer(formula, family = family, data = dat, offset = offset)
3. │ └─base::eval(mc, parent.frame(1L))
4. │ └─base::eval(mc, parent.frame(1L))
5. ├─lme4::glFormula(...)
6. │ └─lme4:::mkFormula(...)
7. │ └─base::eval(mf, parent_env)
8. │ └─base::eval(mf, parent_env)
9. ├─stats::model.frame(...)
10. └─stats::model.frame.default(...)
[ FAIL 5 | WARN 0 | SKIP 0 | PASS 24 ]
Error:
! Test failures.
Execution halted
Flavor: r-devel-linux-x86_64-debian-gcc
Version: 1.0.0
Check: re-building of vignette outputs
Result: ERROR
Error(s) in re-building vignettes:
...
--- re-building ‘steppedwedge.Rmd’ using rmarkdown
Quitting from steppedwedge.Rmd:62-73 [unnamed-chunk-5]
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
<error/rlang_error>
Error in `model.frame.default()`:
! invalid type (closure) for variable '(offset)'
---
Backtrace:
▆
1. └─steppedwedge::analyze(...)
2. ├─lme4::glmer(formula, family = family, data = dat, offset = offset)
3. │ └─base::eval(mc, parent.frame(1L))
4. │ └─base::eval(mc, parent.frame(1L))
5. ├─lme4::glFormula(...)
6. │ └─lme4:::mkFormula(...)
7. │ └─base::eval(mf, parent_env)
8. │ └─base::eval(mf, parent_env)
9. ├─stats::model.frame(...)
10. └─stats::model.frame.default(...)
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Error: processing vignette 'steppedwedge.Rmd' failed with diagnostics:
invalid type (closure) for variable '(offset)'
--- failed re-building ‘steppedwedge.Rmd’
SUMMARY: processing the following file failed:
‘steppedwedge.Rmd’
Error: Vignette re-building failed.
Execution halted
Flavors: r-devel-linux-x86_64-debian-gcc, r-release-linux-x86_64
Version: 1.0.0
Check: examples
Result: ERROR
Running examples in ‘steppedwedge-Ex.R’ failed
The error most likely occurred in:
> ### Name: analyze
> ### Title: Analyze a stepped wedge dataset
> ### Aliases: analyze
>
> ### ** Examples
>
> # Load data
> test_data <- load_data(time ="period", cluster_id = "cluster", individual_id = NULL,
+ treatment = "trt", outcome = "outcome_cont", data = sw_data_example)
Stepped wedge dataset loaded. Discrete time design with 15 clusters, 5 sequences, and 6 time points.
>
> # Analysis example 1: TATE estimand for exposure times 1 through 4
> results_tate <- analyze(dat = test_data, method = "mixed", estimand_type = "TATE",
+ estimand_time = c(1, 4), exp_time = "ETI")
Error in model.frame.default(data = dat, offset = offset, drop.unused.levels = TRUE, :
invalid type (closure) for variable '(offset)'
Calls: analyze ... mkFormula -> eval -> eval -> <Anonymous> -> model.frame.default
Execution halted
Flavors: r-devel-linux-x86_64-fedora-clang, r-devel-linux-x86_64-fedora-gcc, r-devel-windows-x86_64
Version: 1.0.0
Check: tests
Result: ERROR
Running ‘testthat.R’
Running the tests in ‘tests/testthat.R’ failed.
Complete output:
> # This file is part of the standard setup for testthat.
> # It is recommended that you do not modify it.
> #
> # Where should you do additional test configuration?
> # Learn more about the roles of various files in:
> # * https://r-pkgs.org/testing-design.html#sec-tests-files-overview
> # * https://testthat.r-lib.org/articles/special-files.html
>
> library(testthat)
> library(steppedwedge)
>
> test_check("steppedwedge")
Stepped wedge dataset loaded. Discrete time design with 2 clusters, 2 sequences, and 3 time points.
Saving _problems/test-analyze_data-33.R
Saving _problems/test-analyze_data-40.R
Saving _problems/test-analyze_data-47.R
Saving _problems/test-analyze_data-78.R
Saving _problems/test-analyze_data-88.R
Stepped wedge dataset loaded. Discrete time design with 2 clusters, 2 sequences, and 3 time points.
Stepped wedge dataset loaded. Discrete time design with 2 clusters, 2 sequences, and 3 time points.
[ FAIL 5 | WARN 0 | SKIP 0 | PASS 24 ]
══ Failed tests ════════════════════════════════════════════════════════════════
── Error ('test-analyze_data.R:32:3'): Correct model type and estimand_type for IT mixed model ──
Error in `model.frame.default(data = dat, offset = offset, drop.unused.levels = TRUE, formula = outcome ~ factor(time) - 1 + treatment + (1 + cluster_id) + (1 + ij))`: invalid type (closure) for variable '(offset)'
Backtrace:
▆
1. └─steppedwedge::analyze(...) at test-analyze_data.R:32:3
2. ├─lme4::lmer(formula, data = dat, offset = offset)
3. │ └─base::eval(mc, parent.frame(1L))
4. │ └─base::eval(mc, parent.frame(1L))
5. ├─lme4::lFormula(...)
6. │ └─lme4:::mkFormula(...)
7. │ └─base::eval(mf, parent_env)
8. │ └─base::eval(mf, parent_env)
9. ├─stats::model.frame(...)
10. └─stats::model.frame.default(...)
── Error ('test-analyze_data.R:39:3'): Correct model type and estimand_type for ETI mixed model, TATE ──
Error in `model.frame.default(data = dat, offset = offset, drop.unused.levels = TRUE, formula = outcome ~ factor(time) - 1 + factor(exposure_time) + (1 + cluster_id) + (1 + ij))`: invalid type (closure) for variable '(offset)'
Backtrace:
▆
1. └─steppedwedge::analyze(...) at test-analyze_data.R:39:3
2. ├─lme4::lmer(formula, data = dat, offset = offset)
3. │ └─base::eval(mc, parent.frame(1L))
4. │ └─base::eval(mc, parent.frame(1L))
5. ├─lme4::lFormula(...)
6. │ └─lme4:::mkFormula(...)
7. │ └─base::eval(mf, parent_env)
8. │ └─base::eval(mf, parent_env)
9. ├─stats::model.frame(...)
10. └─stats::model.frame.default(...)
── Error ('test-analyze_data.R:46:3'): Correct model type and estimand_type for ETI mixed model, PTE ──
Error in `model.frame.default(data = dat, offset = offset, drop.unused.levels = TRUE, formula = outcome ~ factor(time) - 1 + factor(exposure_time) + (1 + cluster_id) + (1 + ij))`: invalid type (closure) for variable '(offset)'
Backtrace:
▆
1. └─steppedwedge::analyze(...) at test-analyze_data.R:46:3
2. ├─lme4::lmer(formula, data = dat, offset = offset)
3. │ └─base::eval(mc, parent.frame(1L))
4. │ └─base::eval(mc, parent.frame(1L))
5. ├─lme4::lFormula(...)
6. │ └─lme4:::mkFormula(...)
7. │ └─base::eval(mf, parent_env)
8. │ └─base::eval(mf, parent_env)
9. ├─stats::model.frame(...)
10. └─stats::model.frame.default(...)
── Error ('test-analyze_data.R:77:3'): Model coefficients are returned correctly ──
Error in `model.frame.default(data = dat, offset = offset, drop.unused.levels = TRUE, formula = outcome ~ factor(time) - 1 + treatment + (1 + cluster_id) + (1 + ij))`: invalid type (closure) for variable '(offset)'
Backtrace:
▆
1. └─steppedwedge::analyze(...) at test-analyze_data.R:77:3
2. ├─lme4::lmer(formula, data = dat, offset = offset)
3. │ └─base::eval(mc, parent.frame(1L))
4. │ └─base::eval(mc, parent.frame(1L))
5. ├─lme4::lFormula(...)
6. │ └─lme4:::mkFormula(...)
7. │ └─base::eval(mf, parent_env)
8. │ └─base::eval(mf, parent_env)
9. ├─stats::model.frame(...)
10. └─stats::model.frame.default(...)
── Error ('test-analyze_data.R:87:3'): Function handles different family and link functions ──
Error in `model.frame.default(data = dat, offset = offset, drop.unused.levels = TRUE, formula = outcome ~ factor(time) - 1 + treatment + (1 + cluster_id) + (1 + ij))`: invalid type (closure) for variable '(offset)'
Backtrace:
▆
1. └─steppedwedge::analyze(...) at test-analyze_data.R:87:3
2. ├─lme4::glmer(formula, family = family, data = dat, offset = offset)
3. │ └─base::eval(mc, parent.frame(1L))
4. │ └─base::eval(mc, parent.frame(1L))
5. ├─lme4::glFormula(...)
6. │ └─lme4:::mkFormula(...)
7. │ └─base::eval(mf, parent_env)
8. │ └─base::eval(mf, parent_env)
9. ├─stats::model.frame(...)
10. └─stats::model.frame.default(...)
[ FAIL 5 | WARN 0 | SKIP 0 | PASS 24 ]
Error:
! Test failures.
Execution halted
Flavors: r-devel-linux-x86_64-fedora-clang, r-devel-linux-x86_64-fedora-gcc
Version: 1.0.0
Check: re-building of vignette outputs
Result: ERROR
Error(s) in re-building vignettes:
--- re-building ‘steppedwedge.Rmd’ using rmarkdown
Quitting from steppedwedge.Rmd:62-73 [unnamed-chunk-5]
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
<error/rlang_error>
Error in `model.frame.default()`:
! invalid type (closure) for variable '(offset)'
---
Backtrace:
▆
1. └─steppedwedge::analyze(...)
2. ├─lme4::glmer(formula, family = family, data = dat, offset = offset)
3. │ └─base::eval(mc, parent.frame(1L))
4. │ └─base::eval(mc, parent.frame(1L))
5. ├─lme4::glFormula(...)
6. │ └─lme4:::mkFormula(...)
7. │ └─base::eval(mf, parent_env)
8. │ └─base::eval(mf, parent_env)
9. ├─stats::model.frame(...)
10. └─stats::model.frame.default(...)
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Error: processing vignette 'steppedwedge.Rmd' failed with diagnostics:
invalid type (closure) for variable '(offset)'
--- failed re-building ‘steppedwedge.Rmd’
SUMMARY: processing the following file failed:
‘steppedwedge.Rmd’
Error: Vignette re-building failed.
Execution halted
Flavors: r-devel-linux-x86_64-fedora-clang, r-devel-linux-x86_64-fedora-gcc, r-devel-windows-x86_64
Version: 1.0.0
Check: tests
Result: ERROR
Running 'testthat.R' [5s]
Running the tests in 'tests/testthat.R' failed.
Complete output:
> # This file is part of the standard setup for testthat.
> # It is recommended that you do not modify it.
> #
> # Where should you do additional test configuration?
> # Learn more about the roles of various files in:
> # * https://r-pkgs.org/testing-design.html#sec-tests-files-overview
> # * https://testthat.r-lib.org/articles/special-files.html
>
> library(testthat)
> library(steppedwedge)
>
> test_check("steppedwedge")
Stepped wedge dataset loaded. Discrete time design with 2 clusters, 2 sequences, and 3 time points.
Saving _problems/test-analyze_data-33.R
Saving _problems/test-analyze_data-40.R
Saving _problems/test-analyze_data-47.R
Saving _problems/test-analyze_data-78.R
Saving _problems/test-analyze_data-88.R
Stepped wedge dataset loaded. Discrete time design with 2 clusters, 2 sequences, and 3 time points.
Stepped wedge dataset loaded. Discrete time design with 2 clusters, 2 sequences, and 3 time points.
[ FAIL 5 | WARN 0 | SKIP 0 | PASS 24 ]
══ Failed tests ════════════════════════════════════════════════════════════════
── Error ('test-analyze_data.R:32:3'): Correct model type and estimand_type for IT mixed model ──
Error in `model.frame.default(data = dat, offset = offset, drop.unused.levels = TRUE, formula = outcome ~ factor(time) - 1 + treatment + (1 + cluster_id) + (1 + ij))`: invalid type (closure) for variable '(offset)'
Backtrace:
▆
1. └─steppedwedge::analyze(...) at test-analyze_data.R:32:3
2. ├─lme4::lmer(formula, data = dat, offset = offset)
3. │ └─base::eval(mc, parent.frame(1L))
4. │ └─base::eval(mc, parent.frame(1L))
5. ├─lme4::lFormula(...)
6. │ └─lme4:::mkFormula(...)
7. │ └─base::eval(mf, parent_env)
8. │ └─base::eval(mf, parent_env)
9. ├─stats::model.frame(...)
10. └─stats::model.frame.default(...)
── Error ('test-analyze_data.R:39:3'): Correct model type and estimand_type for ETI mixed model, TATE ──
Error in `model.frame.default(data = dat, offset = offset, drop.unused.levels = TRUE, formula = outcome ~ factor(time) - 1 + factor(exposure_time) + (1 + cluster_id) + (1 + ij))`: invalid type (closure) for variable '(offset)'
Backtrace:
▆
1. └─steppedwedge::analyze(...) at test-analyze_data.R:39:3
2. ├─lme4::lmer(formula, data = dat, offset = offset)
3. │ └─base::eval(mc, parent.frame(1L))
4. │ └─base::eval(mc, parent.frame(1L))
5. ├─lme4::lFormula(...)
6. │ └─lme4:::mkFormula(...)
7. │ └─base::eval(mf, parent_env)
8. │ └─base::eval(mf, parent_env)
9. ├─stats::model.frame(...)
10. └─stats::model.frame.default(...)
── Error ('test-analyze_data.R:46:3'): Correct model type and estimand_type for ETI mixed model, PTE ──
Error in `model.frame.default(data = dat, offset = offset, drop.unused.levels = TRUE, formula = outcome ~ factor(time) - 1 + factor(exposure_time) + (1 + cluster_id) + (1 + ij))`: invalid type (closure) for variable '(offset)'
Backtrace:
▆
1. └─steppedwedge::analyze(...) at test-analyze_data.R:46:3
2. ├─lme4::lmer(formula, data = dat, offset = offset)
3. │ └─base::eval(mc, parent.frame(1L))
4. │ └─base::eval(mc, parent.frame(1L))
5. ├─lme4::lFormula(...)
6. │ └─lme4:::mkFormula(...)
7. │ └─base::eval(mf, parent_env)
8. │ └─base::eval(mf, parent_env)
9. ├─stats::model.frame(...)
10. └─stats::model.frame.default(...)
── Error ('test-analyze_data.R:77:3'): Model coefficients are returned correctly ──
Error in `model.frame.default(data = dat, offset = offset, drop.unused.levels = TRUE, formula = outcome ~ factor(time) - 1 + treatment + (1 + cluster_id) + (1 + ij))`: invalid type (closure) for variable '(offset)'
Backtrace:
▆
1. └─steppedwedge::analyze(...) at test-analyze_data.R:77:3
2. ├─lme4::lmer(formula, data = dat, offset = offset)
3. │ └─base::eval(mc, parent.frame(1L))
4. │ └─base::eval(mc, parent.frame(1L))
5. ├─lme4::lFormula(...)
6. │ └─lme4:::mkFormula(...)
7. │ └─base::eval(mf, parent_env)
8. │ └─base::eval(mf, parent_env)
9. ├─stats::model.frame(...)
10. └─stats::model.frame.default(...)
── Error ('test-analyze_data.R:87:3'): Function handles different family and link functions ──
Error in `model.frame.default(data = dat, offset = offset, drop.unused.levels = TRUE, formula = outcome ~ factor(time) - 1 + treatment + (1 + cluster_id) + (1 + ij))`: invalid type (closure) for variable '(offset)'
Backtrace:
▆
1. └─steppedwedge::analyze(...) at test-analyze_data.R:87:3
2. ├─lme4::glmer(formula, family = family, data = dat, offset = offset)
3. │ └─base::eval(mc, parent.frame(1L))
4. │ └─base::eval(mc, parent.frame(1L))
5. ├─lme4::glFormula(...)
6. │ └─lme4:::mkFormula(...)
7. │ └─base::eval(mf, parent_env)
8. │ └─base::eval(mf, parent_env)
9. ├─stats::model.frame(...)
10. └─stats::model.frame.default(...)
[ FAIL 5 | WARN 0 | SKIP 0 | PASS 24 ]
Error:
! Test failures.
Execution halted
Flavor: r-devel-windows-x86_64
Version: 1.0.0
Check: tests
Result: ERROR
Running ‘testthat.R’ [5s/9s]
Running the tests in ‘tests/testthat.R’ failed.
Complete output:
> # This file is part of the standard setup for testthat.
> # It is recommended that you do not modify it.
> #
> # Where should you do additional test configuration?
> # Learn more about the roles of various files in:
> # * https://r-pkgs.org/testing-design.html#sec-tests-files-overview
> # * https://testthat.r-lib.org/articles/special-files.html
>
> library(testthat)
> library(steppedwedge)
>
> test_check("steppedwedge")
Stepped wedge dataset loaded. Discrete time design with 2 clusters, 2 sequences, and 3 time points.
Saving _problems/test-analyze_data-33.R
Saving _problems/test-analyze_data-40.R
Saving _problems/test-analyze_data-47.R
Saving _problems/test-analyze_data-78.R
Saving _problems/test-analyze_data-88.R
Stepped wedge dataset loaded. Discrete time design with 2 clusters, 2 sequences, and 3 time points.
Stepped wedge dataset loaded. Discrete time design with 2 clusters, 2 sequences, and 3 time points.
[ FAIL 5 | WARN 0 | SKIP 0 | PASS 24 ]
══ Failed tests ════════════════════════════════════════════════════════════════
── Error ('test-analyze_data.R:32:3'): Correct model type and estimand_type for IT mixed model ──
Error in `model.frame.default(data = dat, offset = offset, drop.unused.levels = TRUE, formula = outcome ~ factor(time) - 1 + treatment + (1 + cluster_id) + (1 + ij))`: invalid type (closure) for variable '(offset)'
Backtrace:
▆
1. └─steppedwedge::analyze(...) at test-analyze_data.R:32:3
2. ├─lme4::lmer(formula, data = dat, offset = offset)
3. │ └─base::eval(mc, parent.frame(1L))
4. │ └─base::eval(mc, parent.frame(1L))
5. ├─lme4::lFormula(...)
6. │ └─lme4:::mkFormula(...)
7. │ └─base::eval(mf, parent_env)
8. │ └─base::eval(mf, parent_env)
9. ├─stats::model.frame(...)
10. └─stats::model.frame.default(...)
── Error ('test-analyze_data.R:39:3'): Correct model type and estimand_type for ETI mixed model, TATE ──
Error in `model.frame.default(data = dat, offset = offset, drop.unused.levels = TRUE, formula = outcome ~ factor(time) - 1 + factor(exposure_time) + (1 + cluster_id) + (1 + ij))`: invalid type (closure) for variable '(offset)'
Backtrace:
▆
1. └─steppedwedge::analyze(...) at test-analyze_data.R:39:3
2. ├─lme4::lmer(formula, data = dat, offset = offset)
3. │ └─base::eval(mc, parent.frame(1L))
4. │ └─base::eval(mc, parent.frame(1L))
5. ├─lme4::lFormula(...)
6. │ └─lme4:::mkFormula(...)
7. │ └─base::eval(mf, parent_env)
8. │ └─base::eval(mf, parent_env)
9. ├─stats::model.frame(...)
10. └─stats::model.frame.default(...)
── Error ('test-analyze_data.R:46:3'): Correct model type and estimand_type for ETI mixed model, PTE ──
Error in `model.frame.default(data = dat, offset = offset, drop.unused.levels = TRUE, formula = outcome ~ factor(time) - 1 + factor(exposure_time) + (1 + cluster_id) + (1 + ij))`: invalid type (closure) for variable '(offset)'
Backtrace:
▆
1. └─steppedwedge::analyze(...) at test-analyze_data.R:46:3
2. ├─lme4::lmer(formula, data = dat, offset = offset)
3. │ └─base::eval(mc, parent.frame(1L))
4. │ └─base::eval(mc, parent.frame(1L))
5. ├─lme4::lFormula(...)
6. │ └─lme4:::mkFormula(...)
7. │ └─base::eval(mf, parent_env)
8. │ └─base::eval(mf, parent_env)
9. ├─stats::model.frame(...)
10. └─stats::model.frame.default(...)
── Error ('test-analyze_data.R:77:3'): Model coefficients are returned correctly ──
Error in `model.frame.default(data = dat, offset = offset, drop.unused.levels = TRUE, formula = outcome ~ factor(time) - 1 + treatment + (1 + cluster_id) + (1 + ij))`: invalid type (closure) for variable '(offset)'
Backtrace:
▆
1. └─steppedwedge::analyze(...) at test-analyze_data.R:77:3
2. ├─lme4::lmer(formula, data = dat, offset = offset)
3. │ └─base::eval(mc, parent.frame(1L))
4. │ └─base::eval(mc, parent.frame(1L))
5. ├─lme4::lFormula(...)
6. │ └─lme4:::mkFormula(...)
7. │ └─base::eval(mf, parent_env)
8. │ └─base::eval(mf, parent_env)
9. ├─stats::model.frame(...)
10. └─stats::model.frame.default(...)
── Error ('test-analyze_data.R:87:3'): Function handles different family and link functions ──
Error in `model.frame.default(data = dat, offset = offset, drop.unused.levels = TRUE, formula = outcome ~ factor(time) - 1 + treatment + (1 + cluster_id) + (1 + ij))`: invalid type (closure) for variable '(offset)'
Backtrace:
▆
1. └─steppedwedge::analyze(...) at test-analyze_data.R:87:3
2. ├─lme4::glmer(formula, family = family, data = dat, offset = offset)
3. │ └─base::eval(mc, parent.frame(1L))
4. │ └─base::eval(mc, parent.frame(1L))
5. ├─lme4::glFormula(...)
6. │ └─lme4:::mkFormula(...)
7. │ └─base::eval(mf, parent_env)
8. │ └─base::eval(mf, parent_env)
9. ├─stats::model.frame(...)
10. └─stats::model.frame.default(...)
[ FAIL 5 | WARN 0 | SKIP 0 | PASS 24 ]
Error:
! Test failures.
Execution halted
Flavor: r-release-linux-x86_64