- using R version 4.6.2 Patched (2026-11-23 r90976)
- using platform: x86_64-pc-linux-gnu
- R was compiled by
gcc-16 (Debian 16.2.0-4) 16.2.0
GNU Fortran (Debian 16.2.0-4) 16.2.0
- running under: Debian GNU/Linux forky/sid
- using session charset: UTF-8
* current time: 2026-11-25 13:26:05 UTC
- checking for file ‘contdid/DESCRIPTION’ ... OK
- this is package ‘contdid’ version ‘0.1.2’
- package encoding: UTF-8
- checking package namespace information ... OK
- checking package dependencies ... OK
- checking if this is a source package ... OK
- checking if there is a namespace ... OK
- checking for executable files ... OK
- checking for hidden files and directories ... OK
- checking for portable file names ... OK
- checking for sufficient/correct file permissions ... OK
- checking whether package ‘contdid’ can be installed ... OK
See the install log for details.
- checking package directory ... OK
- checking for future file timestamps ... OK
- checking DESCRIPTION meta-information ... OK
- checking top-level files ... OK
- checking for left-over files ... OK
- checking index information ... OK
- checking package subdirectories ... OK
- checking code files for non-ASCII characters ... OK
- checking R files for syntax errors ... OK
- checking whether the package can be loaded ... [3s/4s] OK
- checking whether the package can be loaded with stated dependencies ... [2s/3s] OK
- checking whether the package can be unloaded cleanly ... [2s/3s] OK
- checking whether the namespace can be loaded with stated dependencies ... [2s/3s] OK
- checking whether the namespace can be unloaded cleanly ... [3s/3s] OK
- checking loading without being on the library search path ... [2s/3s] OK
- checking use of S3 registration ... OK
- checking dependencies in R code ... OK
- checking S3 generic/method consistency ... OK
- checking replacement functions ... OK
- checking foreign function calls ... OK
- checking R code for possible problems ... [13s/17s] OK
- checking Rd files ... [0s/1s] OK
- checking Rd metadata ... OK
- checking Rd line widths ... OK
- checking Rd cross-references ... OK
- checking for missing documentation entries ... OK
- checking for code/documentation mismatches ... OK
- checking Rd \usage sections ... OK
- checking Rd contents ... OK
- checking for unstated dependencies in examples ... OK
- checking examples ... [3s/3s] ERROR
Running examples in ‘contdid-Ex.R’ failed
The error most likely occurred in:
> base::assign(".ptime", proc.time(), pos = "CheckExEnv")
> ### Name: cont_did
> ### Title: Difference-in-differences with a Continuous Treatment
> ### Aliases: cont_did
>
> ### ** Examples
>
> # build small simulated data
> set.seed(1234)
> df <- simulate_contdid_data(
+ n = 1000,
+ num_time_periods = 4,
+ num_groups = 4,
+ dose_linear_effect = 0,
+ dose_quadratic_effect = 0
+ )
>
> # estimate effects of continuous treatment
> cd_res <- cont_did(
+ yname = "Y",
+ tname = "time_period",
+ idname = "id",
+ dname = "D",
+ data = df,
+ gname = "G",
+ target_parameter = "slope",
+ aggregation = "dose",
+ treatment_type = "continuous",
+ control_group = "notyettreated",
+ biters = 50,
+ cband = TRUE,
+ num_knots = 1,
+ degree = 3,
+ )
Error in eval(e, x, parent.frame()) : object 'period' not found
Calls: cont_did ... eval -> subset -> subset.data.frame -> eval -> eval
Execution halted
- checking for unstated dependencies in ‘tests’ ... OK
- checking tests ... [4s/5s] ERROR
Running ‘testthat.R’ [3s/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(contdid)
>
> test_check("contdid")
Saving _problems/test-cont_did-37.R
Saving _problems/test-cont_did-162.R
[ FAIL 3 | WARN 0 | SKIP 0 | PASS 0 ]
══ Failed tests ════════════════════════════════════════════════════════════════
── Error ('test-cont_did.R:20:3'): test basic functionality ────────────────────
Error in `eval(e, x, parent.frame())`: object 'period' not found
Backtrace:
▆
1. ├─base::suppressWarnings(...) at test-cont_did.R:20:3
2. │ └─base::withCallingHandlers(...)
3. └─contdid::cont_did(...)
4. └─ptetools::pte(...)
5. └─ptetools::compute.pte(...)
6. └─contdid (local) subset_fun(data, g, tp, ...)
7. ├─base::with(...)
8. └─base::with.default(...)
9. └─base::eval(substitute(expr), data, enclos = parent.frame())
10. └─base::eval(substitute(expr), data, enclos = parent.frame())
11. ├─base::subset(this.data, period == tp | period == base.period)
12. └─base::subset.data.frame(this.data, period == tp | period == base.period)
13. └─base::eval(e, x, parent.frame())
14. └─base::eval(e, x, parent.frame())
── Error ('test-cont_did.R:112:5'): changing variable names is ok ──────────────
Error in `eval(e, x, parent.frame())`: object 'G' not found
Backtrace:
▆
1. ├─testthat::expect_silent(...) at test-cont_did.R:111:3
2. │ └─testthat:::quasi_capture(enquo(object), NULL, evaluate_promise)
3. │ ├─testthat (local) .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. ├─base::suppressWarnings(...) at test-cont_did.R:112:5
10. │ └─base::withCallingHandlers(...)
11. └─contdid::cont_did(...)
12. └─ptetools::pte(...)
13. └─ptetools::compute.pte(...)
14. └─contdid (local) subset_fun(data, g, tp, ...)
15. ├─base::with(data, subset(data, G == g | G > tp | G == 0))
16. └─base::with.default(...)
17. └─base::eval(substitute(expr), data, enclos = parent.frame())
18. └─base::eval(substitute(expr), data, enclos = parent.frame())
19. ├─base::subset(data, G == g | G > tp | G == 0)
20. └─base::subset.data.frame(data, G == g | G > tp | G == 0)
21. └─base::eval(e, x, parent.frame())
22. └─base::eval(e, x, parent.frame())
── Error ('test-cont_did.R:145:3'): level event study recovers a nonzero ATT ───
Error in `eval(e, x, parent.frame())`: object 'period' not found
Backtrace:
▆
1. ├─base::suppressWarnings(...) at test-cont_did.R:145:3
2. │ └─base::withCallingHandlers(...)
3. └─contdid::cont_did(...)
4. └─ptetools::pte(...)
5. └─ptetools::compute.pte(...)
6. └─contdid (local) subset_fun(data, g, tp, ...)
7. ├─base::with(...)
8. └─base::with.default(...)
9. └─base::eval(substitute(expr), data, enclos = parent.frame())
10. └─base::eval(substitute(expr), data, enclos = parent.frame())
11. ├─base::subset(this.data, period == tp | period == base.period)
12. └─base::subset.data.frame(this.data, period == tp | period == base.period)
13. └─base::eval(e, x, parent.frame())
14. └─base::eval(e, x, parent.frame())
[ FAIL 3 | WARN 0 | SKIP 0 | PASS 0 ]
Error:
! Test failures.
Execution halted
- checking PDF version of manual ... [4s/7s] OK
- checking HTML version of manual ... [1s/2s] OK
- checking for non-standard things in the check directory ... OK
- DONE
Status: 2 ERRORs