Skip to content

Releases: epiforecasts/cfrnow

cfrnow 0.2.1

Choose a tag to compare

@sbfnk-bot sbfnk-bot released this 10 Aug 08:26
e05b68d

Patch release: no behaviour changes since 0.2.0.

  • distspec is now on CRAN, so it is dropped from Remotes and installed from
    CRAN like cfrnow's other dependencies.

cfrnow 0.2.0

Choose a tag to compare

@sbfnk-bot sbfnk-bot released this 09 Aug 18:25
b7309ec
  • fit_cfr() and simulate_linelist() take a Weibull() onset-to-death (and
    onset-to-recovery) delay, alongside LogNormal() and Gamma().
  • Delay parameterisation now uses distspec's exported natural_params() instead
    of an internal helper; cfrnow requires distspec (>= 0.1.0).
  • New "Stratified and partially-pooled CFR" vignette: no-, complete- and
    partial-pooling fits, with per-group summary() output.
  • pp_check_cfr() runs a posterior-predictive check. It draws replicate line
    lists from the posterior, replays the real-time truncation, and compares
    observed death counts (and recoveries, in a two-outcome fit) and onset-to-death
    delays against the replicates.
  • summary() takes an ascertainment_ratio argument to correct the CFR when
    fatal and non-fatal cases enter the line list at different rates. Defaults to 1.
  • fit_cfr() accepts intercept-free CFR formulas (e.g. cfr ~ 0 + group),
    fitting one logit-CFR per group with cfr_prior on those coefficients.
  • summary() reports a CFR per group for a cfr ~ group fit, one cfr[<group>]
    row per group.

cfrnow 0.1.0

Choose a tag to compare

@sbfnk-bot sbfnk-bot released this 10 Jul 11:12
499a12a

First release.

  • fit_cfr() estimates a real-time case fatality ratio from line-list data with a
    Bayesian mixture-cure survival model. It is registered as an epidist model
    type, so the CFR and the onset-to-death delay both take brms formulas.
  • prepare_cfr_data() turns a line list into model inputs. It sorts each case, at
    a chosen observation cut-off, into an observed death, a resolved non-death, or a
    right-censored survivor.
  • The onset-to-death delay (LogNormal or Gamma) can be co-estimated or held fixed.
    Hold it fixed and you get the Ghani/Nishiura estimator.
  • Pass a recovery_date column and a two-outcome fit also times recoveries.
  • Put a brms formula on the CFR or the delay for covariates or a time-varying
    CFR.
  • simulate_linelist() builds line lists for testing and examples.
  • summary() and print() report the corrected CFR, the delay moments,
    convergence diagnostics, and a flag for when the CFR is only weakly identified.