v3.0.0
rxode2 3.0.0
Breaking Changes
-
The model properties was moved from
$params
to$props
so it does
not conflict with the low levelrxode2
model$params
-
Error when specifying
wd
withoutmodName
-
With Linear and midpoint of a time between two points, how
rxode2
handles missing values has changed. When the missing value is lower
than the requested time, it will look backward until it finds the
first non-missing value (or if all are missing start looking
forward). When the missing value is higher than the requested time,
the algorithm will look forward until it finds the first non-missing
value (or if all are missing, start looking backward). -
The order of ODEs is now only determined by the order of
cmt()
and
d/dt()
. Compartment properties,tad()
and other compartment
related variables no no longer affect compartment sorting. The
optionrxode2.syntax.require.ode.first
no longer does anything. -
The handling of zeros "safely" has changed (see #775)
-
when
safeZero=TRUE
and the denominator of a division expression
is zero, use the Machine's small number/eps
(you can see this
value with.Machine$double.eps
) -
when
saveLog=TRUE
and the x in thelog(x)
is less than or
equal to zero, change this tolog(eps)
-
when
safePow=TRUE
and the expressionx^y
has a zero forx
and a negative number fory
replacex
witheps
.
Since the protection for divide by zero has changed, the results
will also change. This is a more conservative protection mechanism
than was applied previously. -
-
Random numbers from
rxode2
are different when usingdop853
,
lsoda
orindLin
methods. These now seed the random numbers in
the same way asliblsoda
, so the random number provided will be
the same with different solving methods. -
The arguments saved in the
rxSolve
for items likethetaMat
will
be the reduced matrices used in solving, not the full matrices (this
will likely not break very many items)
Possible breaking changes (though unlikely)
iCov
is no longer merged to the event dataset. This makes solving
withiCov
slightly faster (#743)
New features
-
You can remove covariances for every omega by piping with
%>% ini(diag())
you can be a bit more granular by removing all
covariances that have eithereta.ka
oreta.cl
by:%>% ini(diag(eta.ka, eta.cl))
or anything with correlations with
eta.cl
with%>% ini(diag(eta.cl))
-
You can also remove individual covariances by
%>% ini(-cov(a, b))
or%>% ini(-cor(a,b))
. -
You can specify the type of interpolation applied for added dosing
records (or other added records) for columns that are kept with the
keep=
option inrxSolve()
. This new option is
keepInterpolation
and can belocf
for last observation carried
forward,nocb
which is the next observation carried backward, as
well asNA
which puts aNA
in all imputed data rows. See #756.-
Note: when interpolation is linear/midpoint for
factors/characters it changes to locf with a warning (#759) -
Also note, that the default keep interpolation is
na
-
-
Now you can specify the interpolation method per covariate in the model:
-
linear(var1, var2)
says bothvar1
andvar2
would use linear
interpolation when they are a time-varying covariate. You could
also uselinear(var1)
-
locf()
declares variables using last observation carried forward -
nocb()
declares variables using next observation carried backward -
midpoint()
declares variables using midpoint interpolation
-
-
linear()
,locf()
,locb()
,midpoint()
,params()
,cmt()
anddvid()
declarations are now ignored when loading arxode2
model withrxS()
-
Strings can be assigned to variables in
rxode2
. -
Strings can now be enclosed with a single quote as well as a double
quote. This limitation was only in the rxode2 using string since
the R-parser changes single quotes to double quotes. (This has no
impact withrxode2({})
and ui/function form). -
More robust string encoding for symengine (adapted from
utils::URLencode()
andutils::URLdecode()
) -
Empty arguments to
rxRename()
give a warning (#688) -
Promoting from covariates to parameters with model piping (via
ini()
) now
allows setting bounds (#692) -
Added
assertCompartmentName()
,assertCompartmentExists()
,
assertCompartmentNew()
,testCompartmentExists()
,
assertVariableExists()
testVariableExists()
,
assertVariableNew()
,assertVariableName()
, and
assertParameterValue()
to verify that a value is a valid nlmixr2
compartment name, nlmixr2 compartment/variable exists in the model,
variable name, or parameter value (#726; #733) -
Added
assertRxUnbounded()
,testRxUnbounded()
,warnRxBounded()
to allownlmixr2
warn about methods that ignore boundaries #760 -
Added functions
tad0()
,tafd0()
,tlast0()
andtfirst0()
that
will give0
instead ofNA
when the dose has not been
administered yet. This is useful for use in ODEs sinceNA
s will
break the solving (so can be used a bit more robustly with models
like Weibull absorption). -
rxode2
is has no more binary link tolotri
, which means that
changes in thelotri
package will not requirerxode2
to be
recompiled (in most cases) and will not crash the system. -
rxode2
also has no more binary linkage toPreciseSums
-
The binary linkage for
dparser
is reduced to C structures only,
making changes in dparser less likely to cause segmentation faults
inrxode2
if it wasn't recompiled. -
A new model property has been added to
$props$cmtProp
and
$statePropDf
. Both are data-frames showing which compartment has
properties (currentlyini
,f
,alag
,rate
anddur
)
in therxode2
ui model. This comes from the lower
level model variable$stateProp
which has this information
encoded in integers for each state. -
A new generic method
rxUiDeparse
can be used to deparse meta
information into more readable expressions; This currently by
default supports lower triangular matrices by lotri, but can be
extended to support other types of objects like 'nlmixr2's
foceiControl()
for instance.
Bug fixes
-
Fix
ui$props$endpoint
when the ui endpoint is defined in terms of
the ode instead of lhs. See #754 -
Fix
ui$props
when the ui is a linear compartment model withoutka
defined. -
Model extraction
modelExtract()
will now extract model properties. Note that the model property ofalag(cmt)
andlag(cmt)
will give the same value. See #745 -
When assigning reserved variables, the parser will error. See #744
-
Linear interpolation will now adjust the times as well as the values
whenNA
values are observed. -
Fix when keeping data has
NA
values that it will not crash R; Also
fixed some incorrectNA
interpolations. See #756 -
When using
cmt()
sometimes the next statement would be corrupted
in the normalized syntax (like for instancelocf
); This bug was
fixed (#763) -
keep
will now error when trying to keep items that are in the
rxode2 output data-frame and will be calculated (#764)
Big change
- At the request of CRAN, combine
rxode2parse
,rxode2random
, and
rxode2et
into this package; The changes in each of the packages are
now placed here:
rxode2et (no changes before merge)
rxode2et 2.0.13
- Fix import of data where there are NA times
rxode2et 2.0.12
- Fix formatting issues identified by m1mac, as requested by CRAN
rxode2et 2.0.11
-
Make the stacking more flexible to help rxode2 have more types of plots
-
Add
toTrialDuration
by Omar Elashkar to convert event data to trial duration data -
Fix Issue #23 and prefer variable values over NSE values
rxode2et 2.0.10
-
Fix dollar sign accessing of objects (like data frames), as pointed
out by @frbrz (issue #16) -
Use
rxode2parse
functions for internal event table creation (where
they were moved to). -
Dropped C++14 and let the system decide.
rxode2et 2.0.9
-
Split off
et()
,eventTable()
and related functions. -
Also split off
rxStack()
andrxCbindStudyIndividual()
in this
package. -
Added a
NEWS.md
file to track changes to the package.
rxode2random (before merge)
- Fix a bug when simulating nested variables (#25)
rxode2random 2.1.0
- Breaking Change changed distributions from the standard C++
<random>
toboost::random
. Since this is not dependent on the
compiler, it makes the random numbers generated from Mac, Windows
and Linux the same for every distribution. Unfortunately with a new
random number transformation, the simulation results will likely be
different than they were before. The exception to this is the
uniform number, which was always the same between platforms.
rxode2random 2.0.13
- Fixed formatting issues (as requested by CRAN and identified on
m1mac
)
rxode2random 2.0.12
-
Added function
dfWishart
which gives (by simulation) an
approximation of the degrees of freedom of a Wishart to match a
rse
value. -
Added function
swapMatListWithCube
which swaps omegaList with
omegaCube values -
Ensure that the outputs are integers (instead of long integers) as
requested by CRAN for some checking functions.
rxode2random 2.0.11
- Fix qassert LTO
rxode2random 2.0.10
- Moved fast factor to
rxode2parse
to allowetTrans
to be moved there
rxode2random 2.0.9
-
Initial release of
rxode2random
, which separates the parallel
safe, random number generation from 'rxode2' into a separate package to
reduce 'rxode2' compilation time. This should make CRAN maintenance
a bit easier. -
Added a
NEWS.md
file to track changes to the package.
rxode2parse (fixed before merging)
- As requested by CRAN remove the C code
SET_TYPEOF
which is no
longer part of the C R API.
rxode2parse 2.0.19
-
Added a evid suffix of 60 for cases where evid=2 adds an on event
(fixes tad() calculation in certain edge cases) -
Initialize all variables to
NA
rxode2parse 2.0.18
-
Removed linear compartment solutions with gradients from rxode2parse
(and rxode2) when compiled with intel c++ compiler (since it crashes
while compiling). -
Fixed
m1mac
string issues as requested by CRAN
rxode2parse 2.0.17
-
Added ability to query R user functions in a rxode2 model (will
force single threaded solve) -
Moved core
rxFunParse
andrxRmFunParse
here so that C and R user
function clashes can be handled -
Model variables now tracks which compartments have a lag-time
defined -
For compartment with steady state doses (NONMEM equivalent SS=1,
SS=2), an additional tracking time-point is added at to track the
time when the lagged dose is given. As an upshot, the lagged dose
will start at the steady state concentration shifted by + ii - lag
inrxode2
(currently for ode systems only) -
This release calculates non bio-availability adjusted duration for
all rates instead of trying to figure the rate duration during
solving. -
Make double assignment an error, ie
a <- b <-
-
NA
times are ignored (with warning) -
Steady state bolus doses with
addl
are treated as non steady state
events (like what is observed inNONMEM
) -
Timsort was upgraded; drop radix support in rxode2 structure
-
etTrans
now supports keeping logical vectors (with the appropriate
version ofrxode2
). -
Security fixes were applied as requested by CRAN
rxode2parse 2.0.16
- Import
data.table
explicitly in the R code (before was imported only in C/C++ code)
rxode2parse 2.0.15
- Updates the make flags to support CXX17.
rxode2parse 2.0.14
-
'linCmt()' translations of 'alpha', 'beta', 'gamma', 'k21', 'k31',
'vc' now error instead of ignoring 'gamma' and 'k31' to give 2 cmt
solution -
transit compartment internal code now changes dose to 0.0 when no
dose has been administered to the depot compartment. This way dosing
to the central compartment (without dosing to the transit
compartment) will not give aNA
for the depot compartment (and
consequently for the central compartment) -
Moved
rxDerived
here and added tests for it here as well. -
Moved
etTransParse
here and added tests for it here as well (makes
up most ofetTrans
). In addition the following changes were made
toetTransParse()
/etTrans()
:-
The internal translation (
etTrans()
) will not drop times when
infusions stop. Before, if the infusion stopped after the last
observation the time when the infusion stopped would be dropped.
This interferes withlinCmt()
models. -
Breaking change/bug fix
evid=2
are considered observations when
translating data to internalrxode2
event structure -
Fix edge case to find infusion duration when it is the first item
of the dosing record at time 0.
-
-
Fixed a bug for certain infusions where the
rate
,ii
and/or
ss
data items were dropped from the output whenaddDosing=TRUE
-
Also have internal functions to convert between classic NONMEM
events and rxode2 events -
Have an internal function that gives information on the linear
compartmental model translation type, which could be useful for
babelmixr2 -
'time' in model is now case insensitive
-
Use function declaration in
rxode2parseGetTranslation()
to
determine thread safety of functions available to rxode2 -
Add check for correct number of function arguments to parser.
-
Like R, known functions can be assigned as a variable and the
function can still be called (while not changing the variable
value). For example you can have a variablegamma
as well as a
functiongamma()
. -
Fix garbled error messages that occur with certain messages.
-
Fixed errors that occurred when using capitalized AMT variables in
the model.
rxode2parse 2.0.13
- Version bump for dparser (so binaries will be built correctly)
rxode2parse 2.0.12
-
Bug fix for strict prototypes
-
Removed
sprintf
as noted by CRAN -
Made
rxode2parse
dll binary independent ofrxode2()
rxode2parse 2.0.11
- Bug fix for strict aliasing as requested by CRAN
rxode2parse 2.0.10
- Use strict aliasing as requested by CRAN
What's Changed
- 684 test for iov simulation by @mattfidler in #685
- Update CITATION link to rxode2 by @billdenney in #691
- Warn for empty arguments to rxRename (and anything using
.quoteCallInfoLines()
by @billdenney in #693 - parameters can be promoted from covariate to parameter with bounds by @billdenney in #694
- 696 $params not working in without ka by @mattfidler in #697
- Error with wd specified and modName not specified by @mattfidler in #698
- Remove HASHTAB by @mattfidler in #703
- Change heading to be a bit more precise by @mattfidler in #712
- Remove rxode2et by @mattfidler in #708
- 476 focei estimation fails with max and abs by @mattfidler in #704
- transfer assertions to rxode2 by @mattfidler in #727
- 733 fix assertions for compartments if they exist by @mattfidler in #734
- more flexible exists by @mattfidler in #737
- 736 tad0 by @mattfidler in #739
- 745 model extract does not work on model properties by @mattfidler in #746
- 744 crash when sequentially updating a model by @mattfidler in #747
- iCov is now treated in etTrans by @mattfidler in #748
- 730 covariates with different extrapolation method by @mattfidler in #749
- Create a function that asserts/tests that the model is a linear compartment model by @mattfidler in #751
- With backward compatibility tests subscript of range warning by @mattfidler in #750
- Missing endpoint by @mattfidler in #754
- Crash when simulating a model with a
dur
column by @mattfidler in #756 - Have simulationModel and family respect locf() types of rules by @mattfidler in #752
- Warning when declaring/using inappropriate interpolation (change to locf) by @mattfidler in #759
- assert/test/warn bounded by @mattfidler in #760
- rxode2 cmt/linear and other interp interaction by @mattfidler in #763
- rxode2 should error in invalid keep items by @mattfidler in #764
- Remove binary linkage with lotri by @mattfidler in #767
- Drop binary linkage to PreciseSums by @mattfidler in #768
- No binary linkage to dparser by @mattfidler in #769
- Use lotri's nearPD by @mattfidler in #771
- Remove unneeded C exports by @mattfidler in #772
- Some of the #defines call the abi by @mattfidler in #773
- Feature request: Allow assignment to strings by @mattfidler in #774
- 0 converted to small double/float when used in a power function by @mattfidler in #775
- Use same random number management when the solver is not
liblsoda
by @mattfidler in #777 - string assign is too strict for use in
nlmixr2est
by @mattfidler in #779 - Warning with solve by @mattfidler in #780
rxode2
pipe out non-diagonal elements by @mattfidler in #781- ini(diag()) doesn't work (though ini(diag) does) by @mattfidler in #783
- Export rxode2 transformation functions _powerD and _powerDi by @mattfidler in #784
- New ordering of states can interfere with C code generation by @mattfidler in #785
- New generic by @mattfidler in #787
- Remove zero and over-limit items in thetaMat, omega and sigma mats by @mattfidler in #788
- New data.table interface by @mattfidler in #791
- the keep interpolaton default should be "na" by @mattfidler in #792
- Fix pkgdown by @mattfidler in #793
Full Changelog: v2.1.3...v3.0.0