NEWS | R Documentation |
News for R Package fastbeta
Changes in version 0.3.2 (2025-03-23)
New Features
Function
seir.canonical
providing a nondimensional interface to a special case (constant transmission, without vital dynamics, without loss of immunity) ofseir
usage. The nondimensional parameters are the basic reproduction number and the ratio of the mean latent period and mean generation interval.A method for
summary
approximating the tail exponents of prevalence from the return value ofseir.canonical
.
Changes in version 0.3.1 (2024-11-22)
Significant User-Visible Changes
Formal argument
init
offastbeta
,fastbeta.bootstrap
,ptpi
, andseir
is repositioned.Formal arguments
sigma
andm
offastbeta
,fastbeta.bootstrap
,ptpi
, andseir
have constant default values (sigma = 1
,m = 1L
) not depending on the values of other arguments.
Bug Fixes
Entry
[2, 2]
of the Jacobian matrix constructed byseir(stochastic = FALSE, useCompiled = FALSE)
was wrong.-
seir
handles more comprehensively the situation in which the number of rows of the matrix returned by deSolve functionlsoda
is less thanlength.out
. It now distinguishes termination due to found roots from termination due to an unsuccessful solver call. Warnings caught by -Wconversion are squashed.
New Features
-
seir
gains logical argumentaggregate
indicating whether latent and infectious compartments should be aggregated. -
seir
argumentsnu
andmu
gain default values. In both cases, it isfunction (t) 0
, indicating no vital dynamics. -
seir.R0
,seir.ee
, andseir.jacobian
for calculating the basic reproduction number, endemic equilibrium, and Jacobian matrix. -
fastbeta.matrix
for calculating lower triangular coefficient matrix.
Installation
Compilation now uses -DSTRICT_R_HEADERS and -DR_NO_REMAP.
Changes in version 0.3.0 (2024-05-17)
Significant User-Visible Changes
Argument
constants
of functionssir
,fastbeta
,fastbeta.bootstrap
, andptpi
is replaced by argumentssigma
,gamma
,delta
,init
,m
, andn
.-
sir
is now a wrapper calling newseir
. Arguments
a
andb
of functionptpi
are replaced by argumentsstart
andend
so that the interface is more similar to that ofwindow
.-
ptpi
returnslist(value, diff, iter, x)
, no longerlist(value, delta, iter, X)
. Simulations
sir.e01
andsir.e02
are replaced byseir.ts01
andseir.ts02
. The replacements have a latent compartment and a different set of attributes reflecting the API ofseir
.
Bug Fixes
More simulations set
tl.params = list(epsilon = .)
to mitigate noise attributable to too big leaps in the adaptive tau-leaping algorithm.-
plot
method for classfastbeta.bootstrap
usesdev.hold
anddev.flush
from grDevices to avoid “incremental” graphical output on some devices.
New Features
Compartmental model is generalized to support multiple infected compartments,
latent and
infectious, resulting in several backwards incompatible changes to the API; see below.
Installation
-
adaptivetau and deSolve are now suggested, not imported, as they are needed only for simulation. Usage of simulated data sets is now everywhere conditional on successful loading of the dependency.
Changes in version 0.2.0 (2023-12-11)
Significant User-Visible Changes
-
sir
expectsconstants = c(S0, I0, R0, gamma, delta)
, no longerconstants = c(gamma, S0, I0, R0)
. -
fastbeta
andfastbeta.bootstrap
expectconstants = c(S0, I0, R0, gamma, delta)
, no longerconstants = c(gamma, S0, I0)
. -
ptpi
gains argumentconstants
and loses argumentstart
. It expectsconstants = c(Sa, Ia, Ra, gamma, delta)
, no longerstart = Sa
. -
fastbeta
returns (modulo attributes)cbind(S, I, R, beta)
, no longercbind(beta, S, I)
. -
ptpi(...)[[1L]]
gives the state at time0
or at timea
conditional on new argumentbackcalc
. The default isa
, no longer (implicitly)0
. -
ptpi(...)[[4L]]
has dimensionsc(b-a+1, 3, iter)
, no longerc(b-a+1, iter)
. Simulation
sir.e01
is generated by the same parameters but is no longer stochastic. Simulationsir.e02
gives the stochastic variant.
New Features
Compartmental model is generalized to support loss of immunity at rate
, resulting in several backwards incompatible changes to the API; see below.
Installation
-
‘data/*.R’ are no longer copied to ‘inst/scripts’ at install time by a
make
rule in ‘src/Makevars’. There is no need: the scripts are preserved due to the setting ofBuildResaveData: no
. Hence ‘src/Makevars’ is removed.
Changes in version 0.1.1 (2023-11-28)
Bug Fixes
Typo in ‘src/sir.c’ triggering -Wformat is fixed.
New Features
Changes are logged in ‘inst/NEWS.Rd’.
-
‘DESCRIPTION’ sets
BuildResaveData: no
, so thatR CMD build
works without --no-resave-data when fastbeta is not installed.
Installation
-
‘data/*.R’ are copied into ‘inst/scripts’ at install time by a
make
rule in ‘src/Makevars’. -
Depends: R (>= 4.3.0)
foramsmath
in PDF output, which was not supported until 4.2.2.