AngusMcLure / PoolPoweR

Power and sample size calculations for surveys using pool testing (AKA group testing)
GNU General Public License v3.0
0 stars 1 forks source link

Update `design_effect()` test to `expect_error` #29

Closed fredjaya closed 7 months ago

fredjaya commented 7 months ago

fi_pool_cluster() now throws an error for extreme cases, change to expect_error for the following true negative.

── Error ('test-design_effect.R:39:3'): design_effect() gives consistent output for basic tests ──
Error in `fi_pool_cluster(pool_size, pool_number, prevalence, correlation, 
    sensitivity, specificity, form)`: Error in integration of likelihoods. Likelihoods do not add to 1 or derivatives of likelihood with respect to parameters do not sum to 0
AngusMcLure commented 7 months ago

Fixed with 0426432. Also slightly modified the description of the some of the test suites (technically I believe none of the integrals should actually be divergent, but they can be so extreme as to appear divergent for numerical integration purposes)