Skip to content

DiSCos

Distributional Synthetic Controls Estimation

v0.1.3 · Mar 7, 2026 · MIT + file LICENSE

Description

The method of synthetic controls is a widely-adopted tool for evaluating causal effects of policy changes in settings with observational data. In many settings where it is applicable, researchers want to identify causal effects of policy changes on a treated unit at an aggregate level while having access to data at a finer granularity. This package implements a simple extension of the synthetic controls estimator, developed in Gunsilius (2023) <doi:10.3982/ECTA18260>, that takes advantage of this additional structure and provides nonparametric estimates of the heterogeneity within the aggregate unit. The idea is to replicate the quantile function associated with the treated unit by a weighted average of quantile functions of the control units. The package contains tools for aggregating and plotting the resulting distributional estimates, as well as for carrying out inference on them.

Downloads

1K

Last 30 days

3684th

1.1K

Last 90 days

1.1K

Last year

Trend: +1148.2% (30d vs prior 30d)

CRAN Check Status

1 ERROR
13 OK
Show all 14 flavors
Flavor Status
r-devel-linux-x86_64-debian-clang OK
r-devel-linux-x86_64-debian-gcc OK
r-devel-linux-x86_64-fedora-clang OK
r-devel-linux-x86_64-fedora-gcc OK
r-devel-macos-arm64 OK
r-devel-windows-x86_64 OK
r-oldrel-macos-arm64 OK
r-oldrel-macos-x86_64 OK
r-oldrel-windows-x86_64 OK
r-patched-linux-x86_64 OK
r-release-linux-x86_64 ERROR
r-release-macos-arm64 OK
r-release-macos-x86_64 OK
r-release-windows-x86_64 OK
Check details (15 non-OK)
OK r-devel-linux-x86_64-debian-clang

*


            
OK r-devel-linux-x86_64-debian-gcc

*


            
OK r-devel-linux-x86_64-fedora-clang

*


            
OK r-devel-linux-x86_64-fedora-gcc

*


            
OK r-devel-macos-arm64

*


            
OK r-devel-windows-x86_64

*


            
OK r-oldrel-macos-arm64

*


            
OK r-oldrel-macos-x86_64

*


            
OK r-oldrel-windows-x86_64

*


            
OK r-patched-linux-x86_64

*


            
WARNING r-release-linux-x86_64

dependencies in R code

Missing or unexported object: ‘CVXR::solve’
ERROR r-release-linux-x86_64

tests

  Running ‘testthat.R’ [108s/130s]
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(DiSCos)
  Loading required package: data.table
  Loading required package: ggplot2
  > 
  > options(datatable.auto.thread = 1)  # Limit data.table to 1 thread
  > Sys.setenv(OMP_NUM_THREADS = 1) # limit environment to 1 thread
  > 
  > test_check("DiSCos")
  Saving _problems/test-DiSCo-13.R
  Saving _problems/test-DiSCo-97.R
  Saving _problems/test-DiSCo-99.R
  Saving _problems/test-DiSCo-112.R
  Saving _problems/test-DiSCo-114.R
  Warning: in are.pargam.valid(z): Parameter BETA is not > 0, invalid
  -- tryStack sys.calls: test_check -> test_dir -> test_files -> test_files_serial -> with_reporter -> lapply -> FUN -> source_file -> test_code -> withRestarts -> withOneRestart -> withCallingHandlers -> eval -> eval -> test_that -> test_code -> withRestarts -> withOneRestart -> withCallingHandlers -> eval -> eval -> expect_no_error -> expect_no_ -> quasi_capture -> .capture -> withRestarts -> withOneRestart -> withCallingHandlers -> eval_bare -> DiSCo -> mclapply.hack -> lapply -> FUN -> myQuant -> extremeStat::distLquantile -> distLfit -> lapply -> FUN -> tryStack -> lmomco::lmom2par -> pargam -> are.pargam.valid -> warning -> are.pargam.valid(z)
  Warning: in pargam(lmom, ...): Parameters can not be computed likely because L1 <= L2 or L2 <= 0
  -- tryStack sys.calls: test_check -> test_dir -> test_files -> test_files_serial -> with_reporter -> lapply -> FUN -> source_file -> test_code -> withRestarts -> withOneRestart -> withCallingHandlers -> eval -> eval -> test_that -> test_code -> withRestarts -> withOneRestart -> withCallingHandlers -> eval -> eval -> expect_no_error -> expect_no_ -> quasi_capture -> .capture -> withRestarts -> withOneRestart -> withCallingHandlers -> eval_bare -> DiSCo -> mclapply.hack -> lapply -> FUN -> myQuant -> extremeStat::distLquantile -> distLfit -> lapply -> FUN -> tryStack -> lmomco::lmom2par -> pargam -> warning -> pargam(lmom, ...)
  Warning: in parln3(lmom, ...): L-skew is negative, try reversing the data Y <- -X, to avoid a log(<0) error
  -- tryStack sys.calls: test_check -> test_dir -> test_files -> test_files_serial -> with_reporter -> lapply -> FUN -> source_file -> test_code -> withRestarts -> withOneRestart -> withCallingHandlers -> eval -> eval -> test_that -> test_code -> withRestarts -> withOneRestart -> withCallingHandlers -> eval -> eval -> expect_no_error -> expect_no_ -> quasi_capture -> .capture -> withRestarts -> withOneRestart -> withCallingHandlers -> eval_bare -> DiSCo -> mclapply.hack -> lapply -> FUN -> myQuant -> extremeStat::distLquantile -> distLfit -> lapply -> FUN -> tryStack -> lmomco::lmom2par -> parln3 -> warning -> parln3(lmom, ...)
  Warning: in parrice(lmom, ...): LCV too small (<0.0236) for Rice as implemented
  -- tryStack sys.calls: test_check -> test_dir -> test_files -> test_files_serial -> with_reporter -> lapply -> FUN -> source_file -> test_code -> withRestarts -> withOneRestart -> withCallingHandlers -> eval -> eval -> test_that -> test_code -> withRestarts -> withOneRestart -> withCallingHandlers -> eval -> eval -> expect_no_error -> expect_no_ -> quasi_capture -> .capture -> withRestarts -> withOneRestart -> withCallingHandlers -> eval_bare -> DiSCo -> mclapply.hack -> lapply -> FUN -> myQuant -> extremeStat::distLquantile -> distLfit -> lapply -> FUN -> tryStack -> lmomco::lmom2par -> parrice -> warning -> parrice(lmom, ...)
  Warning: in are.pargam.valid(z): Parameter BETA is not > 0, invalid
  -- tryStack sys.calls: test_check -> test_dir -> test_files -> test_files_serial -> with_reporter -> lapply -> FUN -> source_file -> test_code -> withRestarts -> withOneRestart -> withCallingHandlers -> eval -> eval -> test_that -> test_code -> withRestarts -> withOneRestart -> withCallingHandlers -> eval -> eval -> expect_no_error -> expect_no_ -> quasi_capture -> .capture -> withRestarts -> withOneRestart -> withCallingHandlers -> eval_bare -> DiSCo -> mclapply.hack -> lapply -> FUN -> myQuant -> extremeStat::distLquantile -> distLfit -> lapply -> FUN -> tryStack -> lmomco::lmom2par -> pargam -> are.pargam.valid -> warning -> are.pargam.valid(z)
  Warning: in pargam(lmom, ...): Parameters can not be computed likely because L1 <= L2 or L2 <= 0
  -- tryStack sys.calls: test_check -> test_dir -> test_files -> test_files_serial -> with_reporter -> lapply -> FUN -> source_file -> test_code -> withRestarts -> withOneRestart -> withCallingHandlers -> eval -> eval -> test_that -> test_code -> withRestarts -> withOneRestart -> withCallingHandlers -> eval -> eval -> expect_no_error -> expect_no_ -> quasi_capture -> .capture -> withRestarts -> withOneRestart -> withCallingHandlers -> eval_bare -> DiSCo -> mclapply.hack -> lapply -> FUN -> myQuant -> extremeStat::distLquantile -> distLfit -> lapply -> FUN -> tryStack -> lmomco::lmom2par -> pargam -> warning -> pargam(lmom, ...)
  Warning: in parrice(lmom, ...): LCV too small (<0.0236) for Rice as implemented
  -- tryStack sys.calls: test_check -> test_dir -> test_files -> test_files_serial -> with_reporter -> lapply -> FUN -> source_file -> test_code -> withRestarts -> withOneRestart -> withCallingHandlers -> eval -> eval -> test_that -> test_code -> withRestarts -> withOneRestart -> withCallingHandlers -> eval -> eval -> expect_no_error -> expect_no_ -> quasi_capture -> .capture -> withRestarts -> withOneRestart -> withCallingHandlers -> eval_bare -> DiSCo -> mclapply.hack -> lapply -> FUN -> myQuant -> extremeStat::distLquantile -> distLfit -> lapply -> FUN -> tryStack -> lmomco::lmom2par -> parrice -> warning -> parrice(lmom, ...)
  Warning: in are.pargam.valid(z): Parameter ALPHA is not > 0, invalid
  -- tryStack sys.calls: test_check -> test_dir -> test_files -> test_files_serial -> with_reporter -> lapply -> FUN -> source_file -> test_code -> withRestarts -> withOneRestart -> withCallingHandlers -> eval -> eval -> test_that -> test_code -> withRestarts -> withOneRestart -> withCallingHandlers -> eval -> eval -> expect_no_error -> expect_no_ -> quasi_capture -> .capture -> withRestarts -> withOneRestart -> withCallingHandlers -> eval_bare -> DiSCo -> mclapply.hack -> lapply -> FUN -> myQuant -> extremeStat::distLquantile -> distLfit -> lapply -> FUN -> tryStack -> lmomco::lmom2par -> pargam -> are.pargam.valid -> warning -> are.pargam.valid(z)
  Warning: in pargam(lmom, ...): Parameters can not be computed likely because L1 <= L2 or L2 <= 0
  -- tryStack sys.calls: test_check -> test_dir -> test_files -> test_files_serial -> with_reporter -> lapply -> FUN -> source_file -> test_code -> withRestarts -> withOneRestart -> withCallingHandlers -> eval -> eval -> test_that -> test_code -> withRestarts -> withOneRestart -> withCallingHandlers -> eval -> eval -> expect_no_error -> expect_no_ -> quasi_capture -> .capture -> withRestarts -> withOneRestart -> withCallingHandlers -> eval_bare -> DiSCo -> mclapply.hack -> lapply -> FUN -> myQuant -> extremeStat::distLquantile -> distLfit -> lapply -> FUN -> tryStack -> lmomco::lmom2par -> pargam -> warning -> pargam(lmom, ...)
  Warning: in parrice(lmom, ...): LCV too small (<0.0236) for Rice as implemented
  -- tryStack sys.calls: test_check -> test_dir -> test_files -> test_files_serial -> with_reporter -> lapply -> FUN -> source_file -> test_code -> withRestarts -> withOneRestart -> withCallingHandlers -> eval -> eval -> test_that -> test_code -> withRestarts -> withOneRestart -> withCallingHandlers -> eval -> eval -> expect_no_error -> expect_no_ -> quasi_capture -> .capture -> withRestarts -> withOneRestart -> withCallingHandlers -> eval_bare -> DiSCo -> mclapply.hack -> lapply -> FUN -> myQuant -> extremeStat::distLquantile -> distLfit -> lapply -> FUN -> tryStack -> lmomco::lmom2par -> parrice -> warning -> parrice(lmom, ...)
  Warning: in are.pargam.valid(z): Parameter BETA is not > 0, invalid
  -- tryStack sys.calls: test_check -> test_dir -> test_files -> test_files_serial -> with_reporter -> lapply -> FUN -> source_file -> test_code -> withRestarts -> withOneRestart -> withCallingHandlers -> eval -> eval -> test_that -> test_code -> withRestarts -> withOneRestart -> withCallingHandlers -> eval -> eval -> expect_no_error -> expect_no_ -> quasi_capture -> .capture -> withRestarts -> withOneRestart -> withCallingHandlers -> eval_bare -> DiSCo -> mclapply.hack -> lapply -> FUN -> myQuant -> extremeStat::distLquantile -> distLfit -> lapply -> FUN -> tryStack -> lmomco::lmom2par -> pargam -> are.pargam.valid -> warning -> are.pargam.valid(z)
  Warning: in pargam(lmom, ...): Parameters can not be computed likely because L1 <= L2 or L2 <= 0
  -- tryStack sys.calls: test_check -> test_dir -> test_files -> test_files_serial -> with_reporter -> lapply -> FUN -> source_file -> test_code -> withRestarts -> withOneRestart -> withCallingHandlers -> eval -> eval -> test_that -> test_code -> withRestarts -> withOneRestart -> withCallingHandlers -> eval -> eval -> expect_no_error -> expect_no_ -> quasi_capture -> .capture -> withRestarts -> withOneRestart -> withCallingHandlers -> eval_bare -> DiSCo -> mclapply.hack -> lapply -> FUN -> myQuant -> extremeStat::distLquantile -> distLfit -> lapply -> FUN -> tryStack -> lmomco::lmom2par -> pargam -> warning -> pargam(lmom, ...)
  Warning: in parln3(lmom, ...): L-skew is negative, try reversing the data Y <- -X, to avoid a log(<0) error
  -- tryStack sys.calls: test_check -> test_dir -> test_files -> test_files_serial -> with_reporter -> lapply -> FUN -> source_file -> test_code -> withRestarts -> withOneRestart -> withCallingHandlers -> eval -> eval -> test_that -> test_code -> withRestarts -> withOneRestart -> withCallingHandlers -> eval -> eval -> expect_no_error -> expect_no_ -> quasi_capture -> .capture -> withRestarts -> withOneRestart -> withCallingHandlers -> eval_bare -> DiSCo -> mclapply.hack -> lapply -> FUN -> myQuant -> extremeStat::distLquantile -> distLfit -> lapply -> FUN -> tryStack -> lmomco::lmom2par -> parln3 -> warning -> parln3(lmom, ...)
  Warning: in parrice(lmom, ...): LCV too small (<0.0236) for Rice as implemented
  -- tryStack sys.calls: test_check -> test_dir -> test_files -> test_files_serial -> with_reporter -> lapply -> FUN -> source_file -> test_code -> withRestarts -> withOneRestart -> withCallingHandlers -> eval -> eval -> test_that -> test_code -> withRestarts -> withOneRestart -> withCallingHandlers -> eval -> eval -> expect_no_error -> expect_no_ -> quasi_capture -> .capture -> withRestarts -> withOneRestart -> withCallingHandlers -> eval_bare -> DiSCo -> mclapply.hack -> lapply -> FUN -> myQuant -> extremeStat::distLquantile -> distLfit -> lapply -> FUN -> tryStack -> lmomco::lmom2par -> parrice -> warning -> parrice(lmom, ...)
  Warning: in are.pargam.valid(z): Parameter ALPHA is not > 0, invalid
  -- tryStack sys.calls: test_check -> test_dir -> test_files -> test_files_serial -> with_reporter -> lapply -> FUN -> source_file -> test_code -> withRestarts -> withOneRestart -> withCallingHandlers -> eval -> eval -> test_that -> test_code -> withRestarts -> withOneRestart -> withCallingHandlers -> eval -> eval -> expect_no_error -> expect_no_ -> quasi_capture -> .capture -> withRestarts -> withOneRestart -> withCallingHandlers -> eval_bare -> DiSCo -> mclapply.hack -> lapply -> FUN -> myQuant -> extremeStat::distLquantile -> distLfit -> lapply -> FUN -> tryStack -> lmomco::lmom2par -> pargam -> are.pargam.valid -> warning -> are.pargam.valid(z)
  Warning: in pargam(lmom, ...): Parameters can not be computed likely because L1 <= L2 or L2 <= 0
  -- tryStack sys.calls: test_check -> test_dir -> test_files -> test_files_serial -> with_reporter -> lapply -> FUN -> source_file -> test_code -> withRestarts -> withOneRestart -> withCallingHandlers -> eval -> eval -> test_that -> test_code -> withRestarts -> withOneRestart -> withCallingHandlers -> eval -> eval -> expect_no_error -> expect_no_ -> quasi_capture -> .capture -> withRestarts -> withOneRestart -> withCallingHandlers -> eval_bare -> DiSCo -> mclapply.hack -> lapply -> FUN -> myQuant -> extremeStat::distLquantile -> distLfit -> lapply -> FUN -> tryStack -> lmomco::lmom2par -> pargam -> warning -> pargam(lmom, ...)
  Warning: in parrice(lmom, ...): LCV too small (<0.0236) for Rice as implemented
  -- tryStack sys.calls: test_check -> test_dir -> test_files -> test_files_serial -> with_reporter -> lapply -> FUN -> source_file -> test_code -> withRestarts -> withOneRestart -> withCallingHandlers -> eval -> eval -> test_that -> test_code -> withRestarts -> withOneRestart -> withCallingHandlers -> eval -> eval -> expect_no_error -> expect_no_ -> quasi_capture -> .capture -> withRestarts -> withOneRestart -> withCallingHandlers -> eval_bare -> DiSCo -> mclapply.hack -> lapply -> FUN -> myQuant -> extremeStat::distLquantile -> distLfit -> lapply -> FUN -> tryStack -> lmomco::lmom2par -> parrice -> warning -> parrice(lmom, ...)
  Warning: in are.pargam.valid(z): Parameter BETA is not > 0, invalid
  -- tryStack sys.calls: test_check -> test_dir -> test_files -> test_files_serial -> with_reporter -> lapply -> FUN -> source_file -> test_code -> withRestarts -> withOneRestart -> withCallingHandlers -> eval -> eval -> test_that -> test_code -> withRestarts -> withOneRestart -> withCallingHandlers -> eval -> eval -> expect_no_error -> expect_no_ -> quasi_capture -> .capture -> withRestarts -> withOneRestart -> withCallingHandlers -> eval_bare -> DiSCo -> mclapply.hack -> lapply -> FUN -> myQuant -> extremeStat::distLquantile -> distLfit -> lapply -> FUN -> tryStack -> lmomco::lmom2par -> pargam -> are.pargam.valid -> warning -> are.pargam.valid(z)
  Warning: in pargam(lmom, ...): Parameters can not be computed likely because L1 <= L2 or L2 <= 0
  -- tryStack sys.calls: test_check -> test_dir -> test_files -> test_files_serial -> with_reporter -> lapply -> FUN -> source_file -> test_code -> withRestarts -> withOneRestart -> withCallingHandlers -> eval -> eval -> test_that -> test_code -> withRestarts -> withOneRestart -> withCallingHandlers -> eval -> eval -> expect_no_error -> expect_no_ -> quasi_capture -> .capture -> withRestarts -> withOneRestart -> withCallingHandlers -> eval_bare -> DiSCo -> mclapply.hack -> lapply -> FUN -> myQuant -> extremeStat::distLquantile -> distLfit -> lapply -> FUN -> tryStack -> lmomco::lmom2par -> pargam -> warning -> pargam(lmom, ...)
  Warning: in parrice(lmom, ...): LCV too small (<0.0236) for Rice as implemented
  -- tryStack sys.calls: test_check -> test_dir -> test_files -> test_files_serial -> with_reporter -> lapply -> FUN -> source_file -> test_code -> withRestarts -> withOneRestart -> withCallingHandlers -> eval -> eval -> test_that -> test_code -> withRestarts -> withOneRestart -> withCallingHandlers -> eval -> eval -> expect_no_error -> expect_no_ -> quasi_capture -> .capture -> withRestarts -> withOneRestart -> withCallingHandlers -> eval_bare -> DiSCo -> mclapply.hack -> lapply -> FUN -> myQuant -> extremeStat::distLquantile -> distLfit -> lapply -> FUN -> tryStack -> lmomco::lmom2par -> parrice -> warning -> parrice(lmom, ...)
  Warning: in are.pargam.valid(z): Parameter BETA is not > 0, invalid
  -- tryStack sys.calls: test_check -> test_dir -> test_files -> test_files_serial -> with_reporter -> lapply -> FUN -> source_file -> test_code -> withRestarts -> withOneRestart -> withCallingHandlers -> eval -> eval -> test_that -> test_code -> withRestarts -> withOneRestart -> withCallingHandlers -> eval -> eval -> expect_no_error -> expect_no_ -> quasi_capture -> .capture -> withRestarts -> withOneRestart -> withCallingHandlers -> eval_bare -> DiSCo -> mclapply.hack -> lapply -> FUN -> myQuant -> extremeStat::distLquantile -> distLfit -> lapply -> FUN -> tryStack -> lmomco::lmom2par -> pargam -> are.pargam.valid -> warning -> are.pargam.valid(z)
  Warning: in pargam(lmom, ...): Parameters can not be computed likely because L1 <= L2 or L2 <= 0
  -- tryStack sys.calls: test_check -> test_dir -> test_files -> test_files_serial -> with_reporter -> lapply -> FUN -> source_file -> test_code -> withRestarts -> withOneRestart -> withCallingHandlers -> eval -> eval -> test_that -> test_code -> withRestarts -> withOneRestart -> withCallingHandlers -> eval -> eval -> expect_no_error -> expect_no_ -> quasi_capture -> .capture -> withRestarts -> withOneRestart -> withCallingHandlers -> eval_bare -> DiSCo -> mclapply.hack -> lapply -> FUN -> myQuant -> extremeStat::distLquantile -> distLfit -> lapply -> FUN -> tryStack -> lmomco::lmom2par -> pargam -> warning -> pargam(lmom, ...)
  Warning: in parrice(lmom, ...): LCV too small (<0.0236) for Rice as implemented
  -- tryStack sys.calls: test_check -> test_dir -> test_files -> test_files_serial -> with_reporter -> lapply -> FUN -> source_file -> test_code -> withRestarts -> withOneRestart -> withCallingHandlers -> eval -> eval -> test_that -> test_code -> withRestarts -> withOneRestart -> withCallingHandlers -> eval -> eval -> expect_no_error -> expect_no_ -> quasi_capture -> .capture -> withRestarts -> withOneRestart -> withCallingHandlers -> eval_bare -> DiSCo -> mclapply.hack -> lapply -> FUN -> myQuant -> extremeStat::distLquantile -> distLfit -> lapply -> FUN -> tryStack -> lmomco::lmom2par -> parrice -> warning -> parrice(lmom, ...)
  Warning: in are.pargam.valid(z): Parameter ALPHA is not > 0, invalid
  -- tryStack sys.calls: test_check -> test_dir -> test_files -> test_files_serial -> with_reporter -> lapply -> FUN -> source_file -> test_code -> withRestarts -> withOneRestart -> withCallingHandlers -> eval -> eval -> test_that -> test_code -> withRestarts -> withOneRestart -> withCallingHandlers -> eval -> eval -> expect_no_error -> expect_no_ -> quasi_capture -> .capture -> withRestarts -> withOneRestart -> withCallingHandlers -> eval_bare -> DiSCo -> mclapply.hack -> lapply -> FUN -> myQuant -> extremeStat::distLquantile -> distLfit -> lapply -> FUN -> tryStack -> lmomco::lmom2par -> pargam -> are.pargam.valid -> warning -> are.pargam.valid(z)
  Warning: in are.pargam.valid(z): Parameter BETA is not > 0, invalid
  -- tryStack sys.calls: test_check -> test_dir -> test_files -> test_files_serial -> with_reporter -> lapply -> FUN -> source_file -> test_code -> withRestarts -> withOneRestart -> withCallingHandlers -> eval -> eval -> test_that -> test_code -> withRestarts -> withOneRestart -> withCallingHandlers -> eval -> eval -> expect_no_error -> expect_no_ -> quasi_capture -> .capture -> withRestarts -> withOneRestart -> withCallingHandlers -> eval_bare -> DiSCo -> mclapply.hack -> lapply -> FUN -> myQuant -> extremeStat::distLquantile -> distLfit -> lapply -> FUN -> tryStack -> lmomco::lmom2par -> pargam -> are.pargam.valid -> warning -> are.pargam.valid(z)
  Warning: in pargam(lmom, ...): Parameters can not be computed likely because L1 <= L2 or L2 <= 0
  -- tryStack sys.calls: test_check -> test_dir -> test_files -> test_files_serial -> with_reporter -> lapply -> FUN -> source_file -> test_code -> withRestarts -> withOneRestart -> withCallingHandlers -> eval -> eval -> test_that -> test_code -> withRestarts -> withOneRestart -> withCallingHandlers -> eval -> eval -> expect_no_error -> expect_no_ -> quasi_capture -> .capture -> withRestarts -> withOneRestart -> withCallingHandlers -> eval_bare -> DiSCo -> mclapply.hack -> lapply -> FUN -> myQuant -> extremeStat::distLquantile -> distLfit -> lapply -> FUN -> tryStack -> lmomco::lmom2par -> pargam -> warning -> pargam(lmom, ...)
  Warning: in are.pargam.valid(z): Parameter ALPHA is not > 0, invalid
  -- tryStack sys.calls: test_check -> test_dir -> test_files -> test_files_serial -> with_reporter -> lapply -> FUN -> source_file -> test_code -> withRestarts -> withOneRestart -> withCallingHandlers -> eval -> eval -> test_that -> test_code -> withRestarts -> withOneRestart -> withCallingHandlers -> eval -> eval -> expect_no_error -> expect_no_ -> quasi_capture -> .capture -> withRestarts -> withOneRestart -> withCallingHandlers -> eval_bare -> DiSCo -> mclapply.hack -> lapply -> FUN -> myQuant -> extremeStat::distLquantile -> distLfit -> lapply -> FUN -> tryStack -> lmomco::lmom2par -> pargam -> are.pargam.valid -> warning -> are.pargam.valid(z)
  Warning: in pargam(lmom, ...): Parameters can not be computed likely because L1 <= L2 or L2 <= 0
  -- tryStack sys.calls: test_check -> test_dir -> test_files -> test_files_serial -> with_reporter -> lapply -> FUN -> source_file -> test_code -> withRestarts -> withOneRestart -> withCallingHandlers -> eval -> eval -> test_that -> test_code -> withRestarts -> withOneRestart -> withCallingHandlers -> eval -> eval -> expect_no_error -> expect_no_ -> quasi_capture -> .capture -> withRestarts -> withOneRestart -> withCallingHandlers -> eval_bare -> DiSCo -> mclapply.hack -> lapply -> FUN -> myQuant -> extremeStat::distLquantile -> distLfit -> lapply -> FUN -> tryStack -> lmomco::lmom2par -> pargam -> warning -> pargam(lmom, ...)
  Warning: in parln3(lmom, ...): L-skew is negative, try reversing the data Y <- -X, to avoid a log(<0) error
  -- tryStack sys.calls: test_check -> test_dir -> test_files -> test_files_serial -> with_reporter -> lapply -> FUN -> source_file -> test_code -> withRestarts -> withOneRestart -> withCallingHandlers -> eval -> eval -> test_that -> test_code -> withRestarts -> withOneRestart -> withCallingHandlers -> eval -> eval -> expect_no_error -> expect_no_ -> quasi_capture -> .capture -> withRestarts -> withOneRestart -> withCallingHandlers -> eval_bare -> DiSCo -> mclapply.hack -> lapply -> FUN -> myQuant -> extremeStat::distLquantile -> distLfit -> lapply -> FUN -> tryStack -> lmomco::lmom2par -> parln3 -> warning -> parln3(lmom, ...)
  Warning: in parrice(lmom, ...): LCV too small (<0.0236) for Rice as implemented
  -- tryStack sys.calls: test_check -> test_dir -> test_files -> test_files_serial -> with_reporter -> lapply -> FUN -> source_file -> test_code -> withRestarts -> withOneRestart -> withCallingHandlers -> eval -> eval -> test_that -> test_code -> withRestarts -> withOneRestart -> withCallingHandlers -> eval -> eval -> expect_no_error -> expect_no_ -> quasi_capture -> .capture -> withRestarts -> withOneRestart -> withCallingHandlers -> eval_bare -> DiSCo -> mclapply.hack -> lapply -> FUN -> myQuant -> extremeStat::distLquantile -> distLfit -> lapply -> FUN -> tryStack -> lmomco::lmom2par -> parrice -> warning -> parrice(lmom, ...)
  Saving _problems/test-DiSCo-163.R
  Saving _problems/test-DiSCo-166.R
  Saving _problems/test-DiSCo-216.R
  Saving _problems/test-DiSCo-224.R
  
  Call:
  DiSCoTEA(disco = disco, agg = "quantile")
  
  Reference: Gunsilius, Florian F. "Distributional synthetic controls." Econometrica 91, no. 3 (2023): 1105-1117. 
  
  No treatment effects to summarize, set graph=TRUE in function call or specify a treatment effect option in `agg`.Saving _problems/test-DiSCoTEA-25.R
  
  Call:
  DiSCoTEA(disco = disco, agg = "cdf")
  
  Reference: Gunsilius, Florian F. "Distributional synthetic controls." Econometrica 91, no. 3 (2023): 1105-1117. 
  
  No treatment effects to summarize, set graph=TRUE in function call or specify a treatment effect option in `agg`.Saving _problems/test-DiSCoTEA-60.R
  
  Call:
  DiSCoTEA(disco = disco, agg = "quantileDiff")
  
  Reference: Gunsilius, Florian F. "Distributional synthetic controls." Econometrica 91, no. 3 (2023): 1105-1117. 
  
  Aggregated Distribution Differences, Quantile Δ 
   Time X_from X_to Quantile Δ Std. Error    [95%  Conf. Band]  
      2   0.00 0.25    -1.7561     1.5609  -3.4356     -1.3386 *
      2   0.25 0.50    -1.8575     3.1431  -4.8640     -0.6412 *
      2   0.50 0.75    -4.5250     4.8535  -9.4400     -2.9192 *
      2   0.75 1.00    -6.9157     5.4630 -12.4064     -5.0669 *
  ---
  Signif. codes: `*' Confidence band for distribution differences does not cover 0
  
  No permutation test performed. 
  Number of pre-treatment periods: 1
  Number of post-treatment periods: 1
  N=10,000
  Saving _problems/test-DiSCoTEA-94.R
  
  Call:
  DiSCoTEA(disco = disco, agg = "quantileDiff")
  
  Reference: Gunsilius, Florian F. "Distributional synthetic controls." Econometrica 91, no. 3 (2023): 1105-1117. 
  
  Aggregated Distribution Differences, Quantile Δ 
   Time X_from X_to Quantile Δ Std. Error    [95%  Conf. Band]  
      2   0.00 0.25    -1.7561     1.5609  -3.4356     -1.3386 *
      2   0.25 0.50    -1.8575     3.1431  -4.8640     -0.6412 *
      2   0.50 0.75    -4.5250     4.8535  -9.4400     -2.9192 *
      2   0.75 1.00    -6.9157     5.4630 -12.4064     -5.0669 *
  ---
  Signif. codes: `*' Confidence band for distribution differences does not cover 0
  
  No permutation test performed. 
  Number of pre-treatment periods: 1
  Number of post-treatment periods: 1
  N=10,000
  Saving _problems/test-DiSCoTEA-128.R
  [ FAIL 13 | WARN 0 | SKIP 0 | PASS 72 ]
  
  ══ Failed tests ════════════════════════════════════════════════════════════════
  ── Error ('test-DiSCo.R:13:3'): mixture weights sum up to 1 ────────────────────
  Error: 'solve' is not an exported object from 'namespace:CVXR'
  Backtrace:
      ▆
   1. └─DiSCos::DiSCo(...) at test-DiSCo.R:13:3
   2.   └─DiSCos:::mclapply.hack(...)
   3.     └─base::lapply(...)
   4.       └─DiSCos (local) FUN(X[[i]], ...)
   5.         └─DiSCos:::DiSCo_mixture(...)
   6.           └─DiSCos:::DiSCo_mixture_solve(...)
  ── Failure ('test-DiSCo.R:97:3'): simplex results in weakly positive weights for mixture ──
  Expected `... <- NULL` not to throw any errors.
  Actually got a <simpleError> with message:
    'solve' is not an exported object from 'namespace:CVXR'
  ── Error ('test-DiSCo.R:99:3'): simplex results in weakly positive weights for mixture ──
  Error in `eval(code, test_env)`: object 'disco' not found
  Backtrace:
      ▆
   1. └─testthat::expect_true(all(disco$weights > -1e-05)) at test-DiSCo.R:99:3
   2.   └─testthat::quasi_label(enquo(object), label)
   3.     └─rlang::eval_bare(expr, quo_get_env(quo))
  ── Failure ('test-DiSCo.R:112:3'): returned quantile functions and cdfs are weakly increasing ──
  Expected `... <- NULL` not to throw any errors.
  Actually got a <simpleError> with message:
    'solve' is not an exported object from 'namespace:CVXR'
  ── Error ('test-DiSCo.R:114:3'): returned quantile functions and cdfs are weakly increasing ──
  Error in `eval(code, test_env)`: object 'disco' not found
  ── Failure ('test-DiSCo.R:163:3'): discrete support works for mixture ──────────
  Expected `... <- NULL` not to throw any errors.
  Actually got a <simpleError> with message:
    'solve' is not an exported object from 'namespace:CVXR'
  ── Error ('test-DiSCo.R:166:3'): discrete support works for mixture ────────────
  Error in `eval(code, test_env)`: object 'disco' not found
  Backtrace:
      ▆
   1. └─testthat::expect_true(...) at test-DiSCo.R:166:3
   2.   └─testthat::quasi_label(enquo(object), label)
   3.     └─rlang::eval_bare(expr, quo_get_env(quo))
  ── Failure ('test-DiSCo.R:216:3'): test that variations of other arguments work ──
  Expected `... <- NULL` not to throw any errors.
  Actually got a <simpleError> with message:
    'solve' is not an exported object from 'namespace:CVXR'
  ── Failure ('test-DiSCo.R:224:3'): test that variations of other arguments work ──
  Expected `... <- NULL` not to throw any errors.
  Actually got a <simpleError> with message:
    'solve' is not an exported object from 'namespace:CVXR'
  ── Error ('test-DiSCoTEA.R:25:3'): quantile works ──────────────────────────────
  Error: 'solve' is not an exported object from 'namespace:CVXR'
  Backtrace:
      ▆
   1. └─DiSCos::DiSCo(...) at test-DiSCoTEA.R:25:3
   2.   └─DiSCos:::mclapply.hack(...)
   3.     └─base::lapply(...)
   4.       └─DiSCos (local) FUN(X[[i]], ...)
   5.         └─DiSCos:::DiSCo_mixture(...)
   6.           └─DiSCos:::DiSCo_mixture_solve(...)
  ── Error ('test-DiSCoTEA.R:60:3'): cdf works ───────────────────────────────────
  Error: 'solve' is not an exported object from 'namespace:CVXR'
  Backtrace:
      ▆
   1. └─DiSCos::DiSCo(...) at test-DiSCoTEA.R:60:3
   2.   └─DiSCos:::mclapply.hack(...)
   3.     └─base::lapply(...)
   4.       └─DiSCos (local) FUN(X[[i]], ...)
   5.         └─DiSCos:::DiSCo_mixture(...)
   6.           └─DiSCos:::DiSCo_mixture_solve(...)
  ── Error ('test-DiSCoTEA.R:94:3'): quantileDiff works ──────────────────────────
  Error: 'solve' is not an exported object from 'namespace:CVXR'
  Backtrace:
      ▆
   1. └─DiSCos::DiSCo(...) at test-DiSCoTEA.R:94:3
   2.   └─DiSCos:::mclapply.hack(...)
   3.     └─base::lapply(...)
   4.       └─DiSCos (local) FUN(X[[i]], ...)
   5.         └─DiSCos:::DiSCo_mixture(...)
   6.           └─DiSCos:::DiSCo_mixture_solve(...)
  ── Error ('test-DiSCoTEA.R:128:3'): cdfDiff works ──────────────────────────────
  Error: 'solve' is not an exported object from 'namespace:CVXR'
  Backtrace:
      ▆
   1. └─DiSCos::DiSCo(...) at test-DiSCoTEA.R:128:3
   2.   └─DiSCos:::mclapply.hack(...)
   3.     └─base::lapply(...)
   4.       └─DiSCos (local) FUN(X[[i]], ...)
   5.         └─DiSCos:::DiSCo_mixture(...)
   6.           └─DiSCos:::DiSCo_mixture_solve(...)
  
  [ FAIL 13 | WARN 0 | SKIP 0 | PASS 72 ]
  Error:
  ! Test failures.
  Execution halted
OK r-release-macos-arm64

*


            
OK r-release-macos-x86_64

*


            
OK r-release-windows-x86_64

*


            

Check History

ERROR 13 OK · 0 NOTE · 0 WARNING · 1 ERROR · 0 FAILURE Mar 9, 2026
ERROR r-release-linux-x86_64

dependencies in R code

Missing or unexported object: ‘CVXR::solve’

Dependency Network

Dependencies Reverse dependencies data.table ggplot2 CVXR pracma Rdpack evmix extremeStat MASS DiSCos

Version History

new 0.1.3 Mar 9, 2026