Changelog
Source:NEWS.md
dMod2 0.16.1
-
derivModealone selects the derivatives a constructor builds:odemodel(),Y(),P(),Pexpl(),Pimpl()andimportPEtab()take one or more of"forward"(default),"reverse","forward-forward"and"forward-reverse", or"none". The build argumentsderivandderiv2are removed:deriv2 = TRUEisderivMode = "forward-forward",deriv = FALSEisderivMode = "none". Passingderivorderiv2is an error. - A second-order direction,
"forward-forward"or"forward-reverse", builds"forward"as well."none"combines with no other direction.odemodel(derivMode = "reverse")builds no forward sensitivities.Pimpl()obtains the reverse directions from the forward ones. -
deriv,deriv2andsweepof a call keep their meaning. A call that asks for a derivative the function object was built without is an error that names the missingderivModedirection;Y(),Pexpl()andPimpl()built without first derivatives no longer return values alone onderiv = TRUE. - The
odemodelobject holds the built directions inattr(, "derivMode").
dMod2 0.16.0
- The plotting theme and color helpers are named after the package:
theme_dMod2(),scale_color_dMod2(),scale_fill_dMod2()(with_cand_div),dMod2_colors,dMod2_colors_cb,dMod2_palette(),dMod2_palettes(),dMod2_gradient(),dMod2_divergent()and their_cbforms; thedModnames are gone.theme_dMod2()draws the axis ticks outside the panel. -
trust()runs the hybrid method of Fides (Fröhlich and Sorger 2022) by default: Gauss-Newton, then BFGS once the trust radius stayed the same for 20 iterations. The BFGS matrix starts from the Gauss-Newton Hessian at the start and is updated along the Gauss-Newton steps, and the radius is kept at the switch.hessianMethod = "gn"keeps plain Gauss-Newton. The sparse path, multiple shooting andboundary = "clip"run Gauss-Newton.mstrust()andprofile()follow the default;em()and FOCEI keep Gauss-Newton. - New settings of
trust()phases:keepRadiusstarts a phase at the radius of the handover, andonStop = "end"ends the run on a value, model, step or stagnation stop instead of handing over.qnControl$hessianInit = "tracked"starts a later BFGS phase from a BFGS matrix updated over the whole run. -
trust()with multiple shooting: a stop on stagnation, value, predicted decrease or gradient reportsconverged = TRUEonly where the full step of the condensed model predicts a decrease of at mostmtol, as in single shooting. -
trust()with multiple shooting: after the natural level function hands over to the filter,iterlimbounds both parts together anditerationscounts both. - A phase of
trust()takesradiusStall, the number of consecutive iterations at an unchanged trust radius after which it hands over to the next phase, the switch of the hybrid method of Fides (Fröhlich and Sorger). -
trust(sparse = TRUE)runs a BFGS phase withqnControl$hessianInit = "gn"as limited-memory BFGS: the sparse Hessian of the objective at the start of the phase, shifted by a multiple of the identity where it is not positive definite, plus the compact correction of Byrd, Nocedal and Schnabel from the lastqnMemorypairs, 10 where it is 0, as a low-rank part of the model.sparse = "auto"takes the sparse path only where every phase takes the Hessian of the objective. -
em()with random effects over several groupings passes every argument oftrust()incontrol$trustControlto the outer search,hessianMethod,phases,switchesandqnControlincluded, and reportsphaseIterations. FOCEI of one grouping readsrinit,rmax,iterlim,ftolandmtol; flatftol,mtol,gtolandxtoljointolControl. Other entries ofcontrol$trustControlare an error. -
em()andmsem()takecontrol$inner = "sqp"for FOCEI and for spike-and-slab and Dirichlet-process random effects. The outer search first runs on inexact modes:innerControl$sqpIterliminner iterations (default 2) from the modes predicted along d eta / d theta, with value and gradient corrected to first order, to the square roots offtolandmtol. It then continues on converged modes, so estimates, value, gradient and Hessian are those of the nested search."nested"stays the default. Fits reportinnerIterationsand, with"sqp",sqpIterations. -
em()andmsem()refuse unknown entries ofcontrol$quadrature,control$saemandcontrol$innerControl, as ofcontrolandcontrol$sparseFit.innerControltakesrinit,rmax,iterlim,steptol,mtol,eigenFloorRelativeandsqpIterlim. -
trust(),trustL1()andmstrust()no longer name the control list of a flat tolerance or quasi-Newton setting such asgtol; like any other argument they do not take, it reaches the objective. -
symmetryDetection(),symmetryReduction()anddiscreteSymmetries()need symident 0.17.0. -
trust()takes the structured quasi-Newton HessianshessianMethod = "sbfgs"and"ssr1"(Dennis, Martínez and Tapia), the Gauss-Newton Hessian of the objective at every iterate plus a correction learned by a BFGS or an SR1 update, and the hybrids"gnsbfgs"and"gnssr1"(Zhou and Chen), which choose at every accepted step between the Gauss-Newton Hessian alone, or plus the residual norm times the identity withqnControl$qnHybridShift = TRUE, and the structured model. The structured secant is that of Dennis, Martínez and Tapia,(J+ - J)'u+from the JacobianJof the predictions and sigmas at the data and the derivativesuof the value in them, generalized to the error models and censored data ofnormL2(); the other terms of a sum, such as a prior, enter with the gradient and Hessian they return. Objectives asked forhessian = "structured"return these data rows in an entrystructureof the objlist, which+stacks; an objective without them gets the secant of gradient and Gauss-Newton Hessian. The BFGS update of"sbfgs"is undamped and restores the secant also where the Gauss-Newton Hessian of the new iterate plus the correction is indefinite along the step.qnControl$qnScaling = "residual"scales the correction with the residual norm|u|(Huschens),qnControl$qnHybridTolsets the switch of the hybrids. The methods run insidephasesand throughmstrust(); the result reportshybridGN, andevalBySourcenames the four new sources.trustL1()refuseshessianMethod. -
distributedComputing()refuses a job whose name a job submitted from another working directory still holds in the folder of a remote node, until that job is purged. -
terminate()of adMod2Jobon SSH nodes or the local machine sends SIGKILL to the tasks that still run 5 seconds after SIGTERM. -
trust()andtrustL1()end on a convergence stop that the Newton decrease held back where the run then ends on the radius without an accepted step that changes the value byftolor more, withconverged = TRUE. On an objective with noise abovemtol, such as a FOCEI marginal, the runs end on that convergence stop at the optimum. -
trust()andtrustL1()end on"stagnation"withconverged = TRUEonly where the full Newton step of the model predicts a decrease of at mostmtol, or where a convergence stop was held back since the last step that changed the value byftolor more. -
constraintStability()takeswidth, the least width of the ramp in the units of the rates, default0, andmargin, the least width relative to the largest eigenvalue modulus, default1e-6, which replaces the controlstabilityMarginofPimpl(). A wide ramp shows the boundary to the model of a trust-region step before the step crosses it. - The gradient of
constraintStability()is exact on a defective double eigenvalue, such as that of a chain of states with equal rates: eigenvalues that coincide within the precision of the eigenvalues take the mean of their derivatives, the trace of the spectral projector times the derivative of the Jacobian. The eigenvalues of a Jacobian with large entries are matched within a precision relative to the norm of the Jacobian. - With spike-and-slab or Dirichlet-process random effects the marginal is the value at the exact modes to first order: the value depends on the modes at first order, and the gradient the inner search leaves at them is removed by one Newton step on the exact inner Hessian. Value and gradient do not depend on the outer tolerances.
- The modes of spike-and-slab and Dirichlet-process random effects are found by the C++ group kernel of FOCEI, all groups in one batched prediction per step, and end where the Gauss-Newton step is below
1e-8;control$sparseFit$trustControlsets the outer search only. -
em(method = "saem")andmsem(method = "saem")fit spike-and-slab random effects, also beside normal and Dirichlet-process ones: per-indicator birth and death moves from the local Gaussian model of the data, the other slab values of the group following along the regression of that model, and a joint random walk on the slab values;probandtaufollow in closed form, an estimatedtaustarts at least at the largest group mode under the slab alone.control$saem$nFlipsets the indicator sweeps per iteration; the acceptance rates of births, deaths and random-walk steps are columns ofstageTrace. -2 log L is that ofmethod = "focei"at the estimate, with the inclusion probabilities from the late draws. With many spike-and-slab effects per group the chain can settle with every effect in the slab andprobnear 1. -
logLik(fit, method = "importance")estimates the marginal log-likelihood of a fit with spike-and-slab random effects at the estimates by importance sampling on the model, with standard error and effective sample size per group. -
em(method = "quadrature")returns the best iterate of the outer loop, not the last. -
control$quadrature$maxNodes(default 1000): a level with more nodes per group is never evaluated. There the level error is estimated by the change from the level below, and a group abovetol / Gis capped. -
convergedof a quadrature fit means stationary at the levels reached: the Newton decrement is belowtolDecrement(stopReason"decrement"), or -2 log L rose after a step on unchanged levels ("resolution"). A small decrement relative to the summed level error does not end the fit. Capped groups are listed in columncappedofstageTraceandcertificate, and in attribute"levels"ofstageTrace. -
plotRandomEffects()draws spike-and-slab random effects:type = "inclusion"gives a heatmap of the probability of a deviation per group and effect;"conditional"and"modes"show draws from the conditional mixture against the prior spike and slab. -
plotTrace()draws the hyperparameters of sparse random effects recorded in the trace. -
plotPars()takes anemfit or a list of them: estimates with Wald intervals, fits side by side. -
residuals(type = "NPDE")andplotResiduals()work for fits with sparse random effects only. - Objective functions take
hessian = "expected":normL2()then returns the expected (Fisher) information of the likelihood in place of the Gauss-Newton Hessian,2 / sigma^2in the prediction and4 / sigma^2in sigma per data point (Student-t:2 (nu + 1)and4 nuover(nu + 3) sigma^2), positive semidefinite also where an error model depends on the parameters.$informationof spike-and-slab fits takes it for the terms without random effects. - The documentation of
em()describes$informationof spike-and-slab fits as an empirical information, positive semidefinite, not a Hessian. -
steadyStates()follows the procedure of Rosenblatt et al. (2016): the cycles of the graph of states are cut first, at a state of a conserved quantity or at a state whose balance is solved for a rate constant of one flux side, and the remaining states and rate constants are solved from balances in amounts. A quantity conserved across compartments is recognized, and networks whose cycles defeated the greedy choice of unknowns are solved. Where no cycle forces a cut, the result solves for states rather than rate constants and can differ in form from earlier versions. -
steadyStates()solves a state from the balance of that state before cutting cycles, where the solution is a ratio of positive sums and every cycle keeps a cut; the states of conserved quantities are left to the cuts. -
steadyStates()cuts a flux side whose terms have separate rate constants when no other cut gives a solution: the fluxes of the side keep free ratiosr_<state>_<j>, new parameters of the transformation, and one rate constant of the side is solved. -
em(method = "saem")with spike-and-slab random effects draws each indicator with the slab value integrated out (Gauss-Hermite on the local model, exact model at the nodes, independence Metropolis-Hastings) and takesprobandtaufrom Rao-Blackwellized statistics; the chain no longer settles with every effect in the slab andprobnear 1.p0is the mean conditional spike probability of the late sweeps. Newcontrol$saem$nodes. -
em(method = "saem")with Dirichlet-process random effects beside spike-and-slab ones takes any number of groups: -2 log L by sequential importance sampling over the partitions withvalueSEbeyond 14 groups, or withcontrol$saem$integral = "importance". - An
emfit asinitofem(method = "saem")with sparse random effects starts the chain at the selected effects of that fit. -
em(method = "saem")with sparse random effects reportsinnerModes, the modes of the approximate marginal at the estimates, andlogLik(method = "importance")starts from them, or frometaModesin a fit without them. - A BFGS phase of
trust()seeded from an indefinite Hessian (hessianInit = "gn"or"exact", or a handover from Gauss-Newton) starts from the absolute values of the Hessian eigenvalues. -
c()of a parvec names an unnamed operand by the argument name,c(p, z = 1). -
plotValues(pseudoLog = TRUE)labels every tick as a power of ten where all are, and every tick as a plain number otherwise. -
discreteSymmetries()handles models with several conditions and events. -
symmetryDetection(mode = "global")reads a reduction with one trafo per condition, keeps the parameter names in the section and the state maps of a discrete symmetry, and prints the coordinates the section pins.
dMod2 0.15.10
constraintStability(pSS, p, weight)penalizes instability only. Withsthe largest eigenvalue modulus of the Jacobian on the conserved manifold, a ramp of widthstabilityMargin * s(default1e-6 * s) belowstabilityTol(default0) rises as the cube of the distance into it, reachesweightper eigenvalue atstabilityToland continues linearly in the residual, quadratically in the value. Value, gradient and Gauss-Newton Hessian are continuous. The argumentsonsetanddurationare removed. The attribute"eigenvalues"lists the eigenvalues on the ramp and beyond with their conditions, half-lives and leading states. Steady states count once where they agree in the parameters, resting states and start values they read.Pimpl()takes the controlstabilityMarginofcontrolsPTC;stabilityTolmust be a number of at least0.importPEtab()adds aconstraintStability()term toobjfor every preequilibration, also returned asstability;stability = FALSEleaves it out.normL2()evaluateshessian = "sparse"in the native chain, with the same sparse Hessian as the R path.trust()andtrustL1()end on"gradient","fvalue"or"preddiff"only where the full Newton step of the model also predicts a decrease of at mostmtol, on the positive part of an indefinite or singular Hessian;trustL1()on the model of the coordinates not held at a kink. Otherwise the run goes on withiniterlim.mtol = 0drops the condition.trust()reuses the evaluation of the start also where the start has attributes besides names, and withsparse = "auto"on the dense path as well.importPEtab()passes the states a noise formula reads as outputs of the observation function, so the objective stays in the native chain.em()continues the search for random effects at the boundary only from a reduction it accepts.The volume terms of the FOCEI marginal are computed in C++.
symmetryDetection(),symmetryReduction()anddiscreteSymmetries()need symident 0.15.0.A sum of objective functions called with
conditions = NULLevaluates all conditions, asnormL2()does.A refined reverse sweep of
normL2()sends the chi2 seed of a condition to the backward solve only where it reaches the states differently from the seed of the value; otherwise the value column answers both, correction included.symmetryDetection(mode = "global")analyzes local identifiability, reduces the directions found and counts the values of the coordinates with the same output, with the maps between them, for several conditions and events as well;globalOptionspasses the settings ofdiscreteSymmetries(). A model the global analysis does not handle gets the reason ininfo$discrete$unsupported. Needs symident 0.15.0.symmetryReduction()limits the section search of each block totimeout = 600seconds by default (Inflets the search run to the end), andallowOpenandallowCheckeddefault toTRUE: an open or checked direction gives a warning, as in symident 0.15.0.symmetryReduction(branch = )takes the chart of one side of the fixed set of a discrete symmetry as the trafo; without it the branch charts are in$alternatives. Needs symident 0.15.0.Each direction of
symmetryDetection()has akindby orbit geometry:"scaling","translation"(constant generator, a line in linear coordinates) or"curved";print()groups the directions by it.compile()and the remote builds ofdistributedComputing()compile objects with theCPPFLAGSof the user Makevars, asR CMD SHLIBdoes;compile()reads the compiler settings anew when the site or user Makevars changes. A source that fails to compile in parallel is an error that names it and shows the compiler output.
dMod2 0.15.9
-
symmetryDetection()andsymmetryReduction()need symident 0.14.0. An added, multiplied or replaced dose on a state under a free exponent or a Hill term moves the power of the state with it, at the start and later, also underequilibrate; an initial value such asB*V + Dof such a state is accepted. An event value withexp(),log(), a non-integer power,sin(),cos()ortan()of a state reads the state at the event, not the initial value. -
discreteSymmetries(), orsymmetryDetection(discrete = TRUE), searches the discrete symmetries of a detection result, other points of the domain with the same output, and reconstructs the maps between them with the fundamental domain;symmetryReduction()holds them in$discrete.symmetryDetection(knownInputs = )declares known functions of time. -
trust()runs one optimizer on dense and sparse Hessians: the sparse path solves the subproblem of the same steps on sparse Cholesky factors and takes every setting oftrust()for a Hessian of the objective ("gn","exact"), bounds and phases included.sparse = "auto"takes it above 100 parameters where a step costs fewer flops than a dense one, by the symbolic factorization;options(dMod2.sparseAuto = list(fill = ))keeps the rule by fill. -
hessian = "sparse"may return part of a Hessian as a low-rank partlowrank(seeobjlist()), whichtrust(),profile(),vcov(), the restricted likelihood ofalign()and the results ofem()add by Woodbury. -
align()keeps the Hessian of large alignments sparse. The normalization of the values per block enters it as a sparse part plus a low-rank one, and an experiment is split into conditions of at most 16 biological values, so the derivatives per condition stay small. -
em()andalign()with random effects keep the Hessian sparse where a group couples many parameters, as a random scale per gel does: the Schur complement over the random effects of such a group and the curvature of the volume term of the group enter as low-rank parts. FOCEI runs one outer optimizer on dense and sparse Hessians, which reach the same fit. -
align()with random effects gives standard errorsNAinstead of an error where the Gauss-Newton information of the random effects is singular.
dMod2 0.15.8
-
laplace()is removed. A Laplace prior has no mass at 0, so the deviations it sets to 0 at the joint mode are not a selection by the marginal likelihood;spikeSlab()anddirichletProcess()select deviations, andtrustL1()keeps the L1 penalty.em()takes the settings of the sparse fit incontrol$sparseFit, formerlycontrol$laplace, and returns nostrengths. - The guide chapter on sparse random effects is Sparse deviations, the methods article Sparsity priors, both under new addresses. The methods article describes the Dirichlet process as a grouping of the groups and the clustered lasso,
fuseoftrustL1(), as the penalized counterpart. -
trustL1(one.sided = TRUE)penalizes values belowmubylambda * (mu - p)and leaves values above free: a parameter onmustays there only while the objective pulls it down by at mostlambda, andmuis no lower bound. -
profile()does not double a step it has just shrunk. -
importPEtab()evaluates a prior without theparameterScaleprefix on the linear parameter: for a parameter onlogorlog10scale at the back-transformed value, without a Jacobian term, as other PEtab tools do. A plainnormalorlaplaceprior on such a parameter is accepted. -
exportSbml()writes an event withmethod = "add"or"multiply"asx + valueorx * valueon the old value. -
slurmCluster()withoutwalltimeleaves out the directive lines of the job script template whose field has no value, so the shipped template runs without one. - The flags of
compile(args = )reach the link as well. - Composing two functions defined for different single conditions with
*is an error. - The methods articles, the guide, the example projects and the reference pages are corrected where they did not match the code or the mathematics, among them the partition sum of the Dirichlet process, the hard case of the trust-region subproblem, the regularity of steady-state roots, the scaling test of the symmetry detection and the growth criterion of multiple shooting.
- The README links the guide chapters instead of repeating them.
dMod2 0.15.7
-
detectFreeCores()inside a SLURM job counts at most the cores the process may use, asparallelly::availableCores()reports them, also on macOS.
dMod2 0.15.6
-
symmetryDetection()andsymmetryReduction()need symident 0.13.5. The exact proof of a direction expands the identities under a cap on the terms and solves the state components that an initial value set by parameters gives a direction from the parametrization of that value. Underequilibrate, a direction without exact proof is"verified"with an error bound where the resting states lie on one component of each resting variety, and the Lie order is certified for generic values. The order bound counts the points drawn for each random point, ininfo$orderDraws.
dMod2 0.15.5
- The jobs of
distributedComputing()count a task without result on a node that does not answer, or under a SLURM queue that does not, as running:check()reports it as not reachable, andwait()goes on polling. While a node does not answer,wait()doubles the pause between polls up to 10 minutes.
dMod2 0.15.4
- Under
Xs(optionsReverse = list(refine = TRUE))the reverse objective ofnormL2()adds to the value and tochi2the first-order change from the computed trajectory to the one the refined sweep differentiates, which cppDE reports ascorrection, so value and gradient belong to one function; that value need not be closer to the exact one. A call withderiv = FALSEsweeps as well. The change is the attributecorrectionof the result. The sweeps ofem()andmsem()and multiple shooting run without refine, andem()refuses a prediction with it. Needs cppDE 0.13.12.
dMod2 0.15.3
trust()ends withstopReason = "radius"once a step does not change the parameters in floating point, also with the defaultrmin = 0and where the value at the iterate differs between evaluations, as the Laplace marginal ofem()andmsem()can. UnderqnControl = list(hessianReseed = "stall")a quasi-Newton phase reseeds first, as at a stall.With sparse random effects,
em()andmsem()drop the BFGS correction of the model Hessian, in the search of the random effect modes and in the joint fit, when a step shows no positive curvature, so the search returns to the model Hessian.
dMod2 0.15.2
The refit in each step of
profile()starts at the radiusrinitofoptControl, also for a parameter on a small scale, such as the validation parameter of a prediction profile.subset()of an equation list keeps a state that a kept reaction does not change but whose rate depends on it, as a catalyst.plotCombined(errfn = )andplotPrediction(errfn = )draw the sigma band only where the error model gives a sigma and plot an observable without one.plotArray(fixed = )adds the parameters held fixed in the profiles to every parameter set, so it plots the predictions along profiles computed withfixed.
dMod2 0.15.1
American spelling throughout:
trust(stepControl = list(regularize = ))replacesregularise, the attributerunof the result ofmstrust()namesoptimizerandoptimizerArgsinstead ofoptimiserandoptimiserArgs, and the sequential palette"grey"of [dMod_palettes()] is"gray".wide2long(),%bmm%,rref(),nullZ()andsubmatrix()are no longer exported, andggopen()is removed.as.data.frame()of a prediction returns the long format ofwide2long(), with a columnsigma.
dMod2 0.15.0
New
constraintStability(pSS, p), a term of the objective that keeps the steady state of aPimpl()stable: for every eigenvalue of the Jacobian at the steady state on the manifold of the conserved quantities, the square of how far the real part passes an onset, scaled toweightwhere the real part reaches thestabilityTolofpSS. Zero below the onset, with exact gradient and Gauss-Newton Hessian; the onset defaults to a decay slower than the data last.Pimpl(deriv2 = TRUE)provides the second derivatives it needs. WithcontrolsPTC = list(stability = FALSE)the steady state may be unstable, and the term goes on rising there instead of the evaluation failing.plotValues()takes a named list of fit collections, one panel each and each ranked separately, and withrelativedraws the values above the best of each collection or above a given value.plotValues(),plotPars()andas.parvec()take the result ofmstrust()as it is, andas.parframe()returns a parframe unchanged.align(reml = TRUE)takes the standard errors of the values from the information of the mean parameters alone, the error parameters held at their estimates (Lindstrom and Bates 1990).The integral of
em()over sparse random effects is formed in natural parameters, without the center of the quadratic expansion, in C++ group by group where no Dirichlet-process random effect joins groups. The spike-and-slab random effects of a group are integrated exactly, by a depth-first sum over their subsets that leaves out subtrees below a bound, within a budget of nodes instead of a limit on their number. Where the data couple factors, or the sum would exceed the budget, the expectation consistent (EC) approximation runs as a convergent double loop with Newton steps in both loops; EC converges where the data tie coordinates closely or do not see them. Mean field andcontrol$laplace$couplingare gone, with the fallback to mean field.The native evaluation chain takes observables and error models that read
time.em()with Laplace, spike-and-slab or Dirichlet-process random effects follows the parameter transformations, steady states, ODE, events, observables and error model from every such random effect to the measured names of the group. One that reaches none of them rests at 0 with the prior: the group searches the mode without it, the integral and the hyperparameter updates leave it out, and$randommarks it in a columndata. A hyperparameter all of whose random effects reach no data is an error. Every expression is read with the names that are 0 in the condition set to 0, so that a state that starts at 0 and that nothing drives passes no random effect on, and a root of a steady state depends only on the inputs that the equations and conservation rows of the steady state reach.The second derivatives of the Laplace marginal and of the FOCEI volume term by forward over reverse take the gradients of their traces direction by direction, each from a forward pass along one random effect, where that is cheaper than a backward sweep along all of them per random effect.
msem(sd = )takes a vector named by the parameters it perturbs; an unnamed vector of several entries is an error. The table ofmsem()has the largest absolute entry of the gradient of every start (gradient).em()with sparse random effects finds the modes of the random effects group by group, bytrust()where a group has no Laplace coordinates and bytrustL1()where it has, in place of one trust region over the random effects of all groups. The search differentiates the model in the random effects of the group only, adds a BFGS correction to the Gauss-Newton Hessian and ends at thetolControlofcontrol$laplace$trustControl, where given. A group starts from the lowest of the predicted modes and the minima found at the last four distinct accepted points, as the inner problem of a group may have several local minima; at the start of the fit and every 25 accepted steps the search also runs from 0 and from two starts around the modes.The model Hessian of the outer trust region of
em()with sparse random effects under forward over reverse is built from Gauss-Newton blocks throughout, which keeps it positive semidefinite; the exact rows of the data Hessian in the random effects enter the gradient and the shift of the modes.The fits of
em()with sparse random effects count why evaluations of their trust region failed (failures, also a column of the table ofmsem()). Every start ofmsem()runs to convergence, all starts at once;msem(budget = )is gone.msem(which = )fits a part of the starts, so that tasks ofdistributedComputing()share one multistart, andget()joins their fits into one.residuals(type = "NPDE")of anem()fit draws a reading at or below the limit given the other readings of the same group, on the Gaussian copula of the simulations, which stay uncensored. The NPDE of a group are then independent under the model also with censored readings. The pde is the mid-rank of a reading among the simulations.detectFreeCores()inside a SLURM job takes the cores the job was given and bound to.Multiple shooting with
nodes = "auto"counts a turning point of the data where the replicate means reverse by more than the range that their noise reaches over the series in one draw of a thousand. The noise is that of the replicate means, fromsigmawhere the data have it, else from the replicates or the scatter of the series. Noise on a plateau adds no segments, and oscillations are also counted withoutsigma.
dMod2 0.14.8
Pimpl(): a state whose reactions all vanish at the steady state rests. It takes the value from the input, 0 where the input has none, and is not among the parameters.Alignment models compile into
align/<host>_<process>/of the output directory, so processes that build the same model at once share no file.plotVPC(pc = TRUE)leaves out the readings whose population prediction is not positive.confint(method = "profile")of anem()fit refits with the fit’s derivative mode. The plots ofem()fits order their panels as the model and the data do;plotTrace()orders the stages as they ran.msem(retry = TRUE), the default, draws a start again where the fit from it fails, for instance where the steady state ofPimpl()has no stable root at the start, up tonTriesattempts; the table of starts has theirtriesandstop, the test that ended each trust region.keepFits = TRUEreturns the fit of every start. The fits ofem()havestopReason.align()takes the standard errors of a fit without random terms from the exact Hessian at the fit, and the fallback where the marginal Hessian is not positive definite from the expected information, positive semidefinite by construction.compile()reuses the objects of earlier calls in the same directory.The help pages of the mixed-effects functions have an example each; what takes longer than seconds is not run.
dMod2 0.14.7
The website https://dmodverse.github.io/dMod2/ replaces the vignettes. The site guide has eleven chapters: setting up models, symmetries, sensitivities, optimization, profile likelihood, prediction uncertainty, nonlinear mixed-effects models, group-specific effects, alignment of relative data measurements, PEtab import and export, remote computing. The chapters on optimization and on mixed-effects models derive the methods of
trust(),mstrust(),trustL1(), multiple shooting, FOCEI, quadrature, Laplace EM and SAEM and compare them. The site also has the reference by topic and the example projects as articles.The applications that were demos are example projects in
examples/of the repository: each folder holds the scripts, the saved fits and a README of one project. New example projectspharmacometrics(theophylline, warfarin and mavoglurant, FOCEI and SAEM multistarts with the diagnostics ofem()fits, nlmixr2 on the same model where installed) andTMDD(target-mediated drug disposition with the target at steady state, censored readings, FOCEI and quadrature).License GPL (>= 3).
dMod2 0.14.6
align(reml = TRUE), the default: the error parameters, and the hyperparameters of normal random terms, by restricted likelihood. The parameters of the symbols of the prediction are integrated out under a flat prior as by Lindstrom and Bates: in rounds from the maximum likelihood fit, the log determinant of their Gauss-Newton information at the parameters and modes of the previous round enters the objective with an exact gradient, through FOCEI where the model has random terms. Fits with Laplace, spike-and-slab or Dirichlet-process terms andmethod = "quadrature"stay maximum likelihood;print()and the attributeestimationoffit$parameterssay which,fit$remlRoundscounts the rounds. Where the information is singular, the fit is by maximum likelihood, with a warning.anova()of alignments refuses restricted likelihoods of fits with different parameters of the prediction.align()goes on from the current fit after a variance is set to 0, and the results have those etas amongparameters. Where the Hessian of a fit with random terms is not positive definite at the optimum, the standard errors come from the Gauss-Newton Schur complement over the random effects (fit$seSource).alignmentModel(technical = )names the columns that tell technical replicates apart, such as lanes. Readings that agree in all other columns butvalueandlloqare replaced by their mean before the alignment: geometric, on the log scale, for an error model inprediction, arithmetic otherwise; a sample with censored readings is censored at the mean of the sample readings.Alignment models compile into
getOption("dMod2.outdir"), and processes that build the same model at once take turns.
dMod2 0.14.5
em()sets a variance at the boundary to 0: a normal random effect that forms a block alone and whose standard deviation ends below 0.1 is dropped, the etas of that effect fixed at 0, and the other parameters are fitted again; where that raises -2 log L by at mostcontrol$boundary(default 0.1), the fit without it is returned and names the hyperparameter inboundary, whichmsem()lists per start. The fit stores the random effects indesignand the values given asfixed, andem()andmsem()take a fit asinitand go on from it.FOCEI ends where the trust-region model can gain less than
mtolin the largest region the fit allows (rmax), and after five consecutive rejected trials that leave the objective flat withinftol. The inner search for the modes, of FOCEI and of the quadrature, stops where the Newton step is belowinnerControl$steptol(default 1e-8), so that -2 log L at given parameters does not depend on where the search started. FOCEI over several groupings solves the modes of all components in lock step, with one batched evaluation of the model per round;summary()prints the shrinkage per grouping.em()andmsem()stop with an error where -2 log L of the data is not finite at the start, and FOCEI where a Hessian is not finite. A trial point where the prediction fails, or where the value or derivatives there are not finite, is rejected, in the search for the modes for that subject alone; SAEM keeps the parameters of an iteration where the objective fails at the draws.em(method = "quadrature")and Laplace EM factor the Hessian of the modes instead of inverting it, so that a random effect whose standard deviation collapses to 0 ends the fit. A stage of the quadrature ends where the Hessian is not positive definite, where a Newton step on rebuilt nodes would lower -2 log L by less thantolDecrementor than the nodes resolve, or where a step raised -2 log L by more than a Newton step would gain; the stage trace has the resolution.SAEM evaluates the data term of the draws, and the quadrature that of the nodes, in C++ where the model allows it, as FOCEI does.
msem(budget = )caps the outer trust region of FOCEI, also the one before quadrature, atbudgettimes the iterations of the first fit; quadrature, Laplace EM and SAEM keep their own limits.Spike-and-slab random effects have no upper bound per group: up to 12 of a group are integrated jointly and exactly, more each alone, coupled by the expectation consistent (EC) approximation or mean field (
couplingincontrol). With sparse random effects one coupling holds for the whole fit, EC where it converges at the start, else mean field, reported as"meanFieldFallback".An effect formula leaves a condition whose grouping is missing (
NAin the branch table) without random effect, at the fixed effects.residuals(fit, type = "NPDE"): normalized prediction distribution errors from simulated data sets, decorrelated per group, censored readings by a uniform draw below their simulated fraction, with the tests of mean, variance and normality as attributetests. NewplotVPC(): visual predictive check of anem()fit, prediction corrected withpc = TRUE, stratified by a column of the condition grid, with the fraction of censored readings.plotResiduals()of anem()fit takestype, any of IWRES, CWRES and NPDE, andplotRandomEffects(fit, covariates = )plots the random effects against covariates of the groups. The plots ofem()fits order the conditions naturally.New data sets
warfarin(PK/PD after an oral dose, 32 subjects) andmavoglurant(PK after an intravenous infusion, 120 subjects, 78 on two occasions), from nlmixr2data.
dMod2 0.14.4
profile()returns the attributeends, one row per side with the number of steps and why the side ended: the threshold, a limit, the step limit, or the error of the objective. It solves the path equation with the exact Hessian where the objective returns one withderiv2 = TRUE;deriv2 = FALSEkeeps the Gauss-Newton matrix.verbose = TRUEshows the progress toward the threshold of the contribution named bystop.mstrust()warns with the first error when every fit failed.plotCombined(errfn = )draws one standard deviation of the error model as a band around the prediction.plotData(),plotCombined()andplotPrediction()order the conditions naturally (L2 before L10). A color legend of a single condition, and a legend ofplotProfile()orplotPaths()with a single entry, are left out;plotProfile()andplotPaths()keep the order of a list of profiles.symmetryReduction(allowChecked = )reduces on directions of level"checked", which hold at random points without a proof.distributedComputing()writes the result of a task under a temporary name and renames it once written, so thatcheck()andget()read complete results only; the remote build uses/tmpwhereTMPDIRnames a missing directory.terminate()cancels a SLURM job by job ID.
dMod2 0.14.3
trust()also ends on a rejected Newton step from inside the trust region that predicts a decrease belowmtol.The sparse trust-region step, and the step of multiple shooting, count a numerically singular factor or a failed solve as not positive definite and take the norm of the step and the curvature along it without under- or overflow: a Hessian with flat directions gives a step on the boundary of the region.
dMod2 0.14.2
normL2(data, g * x * p, errmodel = e)evaluates in C++ wherexisXs()of the cppDE backend,Xt(), orXf()for values alone,gandecome fromY(), andpis any product ofPexpl()andPimpl(), sums per condition included, or absent: per condition the transformations, the steady states with their derivatives by the implicit function theorem, the batch solve of the model and the data term, in parallel over the conditions ongetOption("dMod2.cores"). Value, gradient and Hessian, Gauss-Newton or exact, and the adjoint gradient ofsweep = "reverse"equal those of the R evaluation, which every other model takes, as does every model underoptions(dMod2.evaluation = "R").The parallel regions over conditions run on
getOption("dMod2.cores")threads, at most the processors, also for fewer conditions than cores.The checkpoints
Xs()keeps for the reverse sweep are limited to twice the widest batch of conditions, at least 4, and freed withcppDE::releaseStore()once they leave the cache or the backward solve of the native chain used them.A sum of objectives in which one term has a value that is not finite returns that value.
The option
dMod2.batch.checkis removed.
dMod2 0.14.1
The steady states of
Pimpl()are solved in C++ by the solver ofcppDE::ptc(), in the native chain for all conditions of an evaluation at once and in parallel ongetOption("dMod2.cores"), with the same result on any number of cores. A root depends on the parameters, the states inparsand the controls only, so that an objective is the same function of the parameters in every call; identical values are answered from memory, whichkeepRoot = FALSEturns off. The controlarchiveandresetWarmStarts()are removed.Pimpl(controlsPTC = list(stabilityTol = )): a root counts as stable while the real part of the leading eigenvalue on the manifold of the conserved quantities is at moststabilityTol, in the units of the rates; default 0.conservedQuantities(eqnlist)replacesgetTotals()andconservedQuantities(S)on a stoichiometric matrix. A conserved quantity is an amount: the concentrations enter with the volumes of their compartments, also symbolic ones (1*A+1*V*B). A quantity of a single species is named after it.customTotals()checks the same, andPimpl()reads the coefficients at the parameters of each call. A state that no reaction changes is a parameter ofPimpl(), not a conserved total.Pimpl()and the PEtab pre-equilibration keep a conserved moiety at the total where the moiety reactions rest, and totals keep the names of the full network.exportPEtab()takes the observables and the error model as observation functions ofY().exportPEtab(steadyState = )takes thePimpl()of the chain and writes the steady state as a pre-equilibration, conditions with equal parameters sharing one;exportPEtab(events = )writes the events at time 0 that replace a state into the condition table and refuses others. An observable the error model leaves out takes the standard deviations of the observable data, one without data the noise 1, and a fixed parameter that enterspasexp()or10^()has the value it has in the model.log10Transform(states = )transforms the states named, all of them by default.
dMod2 0.14.0
Breaking:
define(),insert(),repar()andbranch(apply = )write a substitution as"lhs <- rhs", e.g.insert(trafo, "x <- exp(x)", x = pars). A"lhs ~ rhs"string or a formula is an error that names the new form;~is left to model formulas.evalConditionResidual()withdfgives the Student-t likelihood ofnormT().Random effects as formulas:
insert()on a branched transformation takes effect formulas such ascl ~ wt + (1 + dose | p | ID). The symbol is replaced by the linear predictor on the scale the transformation gives it, so afterinsert(trafo, "x <- exp(x)", x = "cl")the random effects are normal on the log scale. Fixed effects are coded as bymodel.matrix()over the columns of the branch table, random terms follow lme4 with the IDs of brms for correlation across formulas,gr(ID, dist = )sets the distribution.x ~ 1 + (1 | ID), x = parsandka + v ~ ...apply one right-hand side to many symbols.randomEffects()returns the structure from the transformation or from theP()built from it.New
normal(),laplace(lambda),spikeSlab(prob, tau)anddirichletProcess(concentration, tau), the distributions of a random term. A spike-and-slab deviation is exactly 0 or, with probabilityprob, drawn from N(0, tau^2). UnderdirichletProcess()the groups share the population value or a common deviation in clusters, with the Ewens prior over the partitions and N(0, tau^2) as base measure. Every hyperparameter leftNULLis estimated by marginal maximum likelihood with the other parameters.-
New
em()andmsem(), mixed-effects fits astrust()andmstrust():em(obj, random = randomEffects(p), init, fixed, method)takes the objective of the data and builds the prior itself. A group may own several conditions, conditions without a group enter the fit, random terms over several groupings, nested or crossed, are integrated per connected component, and normal and sparse random effects combine in one fit. Methods:-
"focei", the Laplace approximation of the marginal with exact gradient, censored data by M3 and random effects in the error model; Laplace, spike-and-slab and Dirichlet-process random effects are integrated on the Schur complement of the normal ones, the partitions of a Dirichlet process summed exactly (at most 14 groups), and sparse random effects of one group that the data couple by expectation consistent (control$laplace$coupling, or mean field as a bound). Their hyperparameters move with the other parameters in one trust region: the Schur complement of the fixed parameters takes the sparse random effects at the curvature of their posterior, the curvature of a hyperparameter puts the Newton step at the M-step, and a BFGS correction learns the missing information. Such fits have no Hessian of the marginal: with Laplace and spike-and-slab random effectsvcov()inverts the empirical information of the exact scores of the groups,fit$information, which needs more groups than parameters; with Dirichlet-process ones, whose groups are not independent,vcov()is an error andconfint(method = "profile")gives intervals; -
"quadrature", from the FOCEI fit, on nested sparse grids whose level per group followscontrol$quadrature$tol, with an importance-sampling certificate per group; -
"laplaceEM", the same nodes in an ECM; -
"saem", stochastic approximation with the mu-referenced fixed effects and Omega in closed form; for Dirichlet-process random effects of any number of groups by Gibbs sweeps over the clusters, -2 log L by sequential importance sampling withvalueSE.
msem()perturbs the starts on the scale on which each parameter is unbounded and returns the best fit with the table of starts, whichplotValues()draws as a waterfall;coressplits as inmstrust(). The fit frominitruns first, and every other start ends afterbudget(default 5) times the outer iterations of that fit, withconverged = FALSE. -
em()fits reportomega(standard deviations and correlations with standard errors),random(the modes per group with conditional standard errors, for the sparse distributions the cluster and the probability of 0),strengths,slab,logLik()(soAIC()andBIC()),residuals()of type IRES, IWRES, CWRES, PRES or PWRES,predict(type = ),confint(method = "profile"),anova(),simulate(),summary(),coef(),vcov(),plot(),plotResiduals(),plotTrace(),plotCombined()(data, IPRED and PRED per condition) and the new genericplotRandomEffects(), which compares draws from the conditional distributions of the random effects with their estimated normal, so the shrinkage of the modes does not distort it (type = "modes"for the modes).New
normT(): the Student-t likelihood with fixed degrees of freedom, with exact derivatives and censored data by M3, throughtrust()and every method ofem().em()andmsem()takesparse = "auto"(default),TRUEorFALSE, astrust()does.em()by FOCEI over normal random effects runs the outer trust region on the sparse Hessian wheresparsechooses it: the joint Gauss-Newton Hessian minus the Schur complement of every group plus the volume term, each local to the parameters of the group, for one grouping and for several.summary()and the standard errors of Omega solve the sparse Hessian for the columns they need.The normal prior of
em()returns a sparse Hessian onhessian = "sparse".FOCEI, with normal and with sparse random effects, gets the second derivatives of the volume term by forward over reverse (
control$derivMode = "forward-reverse", the default, for models built withderivMode = c("forward", "reverse", "forward-reverse")): one pass forward along the random effects and a few backward sweeps give the exact gradient, the mode shift and the derivatives of the curvature of every group, at a cost that does not grow with the square of the parameters. The outer trust region takes the Gauss-Newton Schur complement with the volume curvature of the variance parameters from these derivatives; the reported Hessian is exact forward over forward where the model hasderiv2, else the exact Schur complement of the joint Hessian with that volume curvature, exact for models linear in the random effects, andsummary()says so."forward-forward"keeps the second-order sensitivities; a model with only one of the two takes it. In both modes, dense and sparse, the outer model of FOCEI gets an SR1 correction from the changes of the full outer gradient between the last three accepted points: it adds the curvature Gauss-Newton leaves out, negative curvature included, so fewer fits stop at saddles of the Gauss-Newton model.FOCEI in both derivative modes: the inner trust region of the random effects steps on the Gauss-Newton Hessian with an SR1 correction from the accepted steps where that stays positive definite; the outer gradient has the first-order correction for the eta gradient the inner solve leaves at the modes; a rejected step shrinks the radius to a quarter of the step length where that is shorter; the fit ends on the evaluation of the last accepted point. Forward over reverse answers all second-order seeds of a step in one backward sweep.
em()with Laplace, spike-and-slab or Dirichlet-process random effects takes the terms ofobjbesides the data, such as priors and constraints; a term on a hyperparameter or a random effect is an error.Sparse random effects by forward over reverse: the marginal alone needs no second-order sensitivities, so models built without
deriv2also return to expectation consistent after a fall back to mean field.em()says in a message when the models of the fit give second derivatives forward over forward only and namesderivMode = c("forward", "reverse", "forward-reverse");msem()says it once.Removed from the devel-EM layer:
EM()andmsEM()(nowem()andmsem()),omega(),penaltyL1(),emInit(),updateOmegaChol(),makeSubjectNodes(),emObjfn(),sparsify(),scanL1(),gateL1(),selectEB()and the vignette “Structure selection with an estimated penalty”.New
alignmentModel()andalign(): alignment of replicate readings with free expressions for the prediction and the standard deviation. Every symbol is a linear predictor given by a formula inmodel.matrix()coding with random terms, a column with one level per value, numeric or not, andI(dose)a covariate.trafo = c("sj <- 10^sj")sets the scale of a symbol,error = NULLan error model without symbols,prioraconstraintL2()on any parameter, the spread of a random term included; censored readings by M3, a Student-t option. As in blotIt, the experiments connected by shared values form blocks, and per block the mean of the predictors of the first biological symbol is held at 0. Absolute readings, marked in a logical columnabsolute, such as concentrations by targeted mass spectrometry, are predicted by the expressionabsolutein the biological symbols and data columns (the first biological symbol by default, units by the expression), depend on no scaling parameter and may beNAin the columns of the scaling formulas; their block is not normalized but comes out in their units. Every experiment within a connected component of the groups of the random terms is a separate condition, so the Hessian is sparse over them; designs and coefficients are sparse matrices and the standard errors of the values come from a sparse solve.align()starts the coefficients of the first scaling symbol where the predictor of that symbol is, per experiment, the median of the predictors at which the prediction meets the relative readings, runs the fits of a multistart in parallel oncores, one core each, and stops at tolerances ofsqrt(.Machine$double.eps), inner fits included. Methodsprint(),as.datalist(),plotValues()(the starts by rank),plotResiduals(),anova()andsimulate(), plotsplotAligned()andplotScaled(). The demo “alignment” aligns qPCR experiments with undetected wells, and Western blots with a random background per gel together with targeted mass spectrometry, which puts the values in nM.alignmentModel()takes random terms of several groupings, nested or crossed, such as a lane effect per gel and lane shared by the antibodies of a gel beside a background per gel and antibody. They are normal and integrated per connected component; a condition is an experiment within a component, and the normalization blocks follow the fixed parts of the scaling formulas.fit$omegaandfit$randomhave a columngrouping, andplotRandomEffects()draws a panel per grouping and random effect.The objective of an alignment answers all conditions by one prediction and one error-model function: the compiled model is evaluated once at the readings of all conditions, and the derivatives of every condition in the parameters of that condition and the contractions of the backward sweep run in C++, in parallel over the conditions. The error model of an alignment is taken from the prediction, which evaluates it alongside. The backward sweeps of the alignment objective answer several second-order seeds at once, so FOCEI fits it by forward over reverse.
An alignment holds the evaluation that the backward sweeps of prediction and error model share only within one sweep, so a fitted alignment keeps none of it; an error model that depends on no symbol is not evaluated backwards.
The reverse mode: the Hessian of
normL2()withsweep = "reverse"has the curvature of an estimated error model, an error model that is a sum of per-condition ones goes backwards, and so does an observation function that has no parameters at second order.Y(),P()andXs()answer several second-order seeds in one backward sweep.A prediction or observation function whose kernel has a
conditionargument gets the condition of every call, the batch entries getconditions; an observation function answers the backward sweep through the batch entry where it has one.normL2()withtimesas a list evaluates a function of several conditions at the times of each, and the backward sweep sums the cotangents of the conditions in one pass. An error model whose output the prediction holds is taken from there.A cppDE model keeps the batch handles of the last eight request sets.
A sum of objectives holds the terms, not the frame it is built in.
distributedComputing(build = "compile")builds a model of eight or more C++ sources that lie outside the working directory, such as ingetOption("dMod2.outdir").
dMod2 0.13.4
evalConditionResidual()has the parameters that enter only the error model in the gradient and Hessian.An objective called with
hessian = "sparse"returns the Gauss-Newton Hessian as a sparseMatrixassembled from the blocks of the conditions;trust(sparse = TRUE)factorizes it by sparse Cholesky andvcov(which = )solves it for the columns named.datapointL2()returns a sparse Hessian there too.trust()andprofile()takesparse = "auto"(default),TRUEorFALSE."auto"takes the sparse Gauss-Newton Hessian for a minimization without phases, bounds or exact Hessian when there are at least 500 free parameters and the Hessian at the start fills at most 5% of the matrix (options(dMod2.sparseAuto = )), and starts from that evaluation.trust(sparse = TRUE)on an objective that returns a dense Hessian is an error that names the terms of the sum that do.mstrust()passessparsetotrust().profile()on a sparse Hessian decides by the pivots of the LU factorization whether the path equation is singular, by the rule ofvcov(): a pivot at most 1e-14 times the largest. A singular step then takes the pseudo-inverse and reoptimizes as on a dense Hessian, up to 5000 parameters; above, the error names the non-identifiable parameters. The pseudo-inverse step keeps all components.algoControl$W = "identity"moves the profiled parameter alone and reoptimizes the others at every step, without a matrix in the path equation and without a warning on singularity.Requires cppDE 0.13.4, which takes the second derivatives of the inputs of a second-order solve as zero where none are given.
dMod2 0.13.3
distributedComputing()keeps the manifest of a job also in the job folder on every remote node.recover = TRUEwithongiven takes it from there, so a job submitted from another machine is recovered, and a job of the same name that still runs on the nodes is an error also when it was submitted from another machine.distributedComputing()runs on Windows, with the local commands in the sh of Rtools.detectFreeCores()measures the processor load of the local Windows machine, without a warning.compile()compiles in parallel on Windows too, with or without a combinedoutput, andP()andY()pass theircoresto it there.
dMod2 0.13.2
distributedComputing()reports the start of a job as a message, on a SLURM cluster with the job ID and the array tasks. A build writes the build output tobuild.login the job folder, and a failed build is an error that shows the end of that log instead of starting the tasks.plotProfile()leaves more space between the panels, and a narrow panel leaves out the x labels that would overlap.
dMod2 0.13.1
Breaking:
distributedComputing()takes where the tasks run ason:localNode(),sshNodes()orslurmCluster(), each with thecoresof a task. A node is one worker, and a SLURM job hasarrayworkers, the array tasks; the tasks are dealt to the workers in turn.slurmCluster()takeswalltime,memPerCore, the job script andpartition,account,maxRunningand further options ofsbatch.build = c("auto", "compile", "link", "copy")replacescompileandlink, and"auto"compiles on remote nodes. The argumentsmachine,slurm,jobscript,memPerCore,walltime,compileandlinkare gone, andslurmTemplate()names the first argumentlogin.distributedComputing()ships the model files of the objects ininputinstead of every file ofdMod2.outdir. A job of the same name that still runs where the new one would run is an error. The manifest is written before the start, and every job is registered untilpurge(local = TRUE);dMod2Jobs()lists them, andrecoverfinds a job from any working directory. The job haswait()andlog(i), andget()joins parlists withc()and data frames withrbind(), leaving out tasks without a result with a warning.rbind()of parameter frames keeps their attributes and joins the parts of a profile, such as the two sides, into one.confint()sorts the right side of a profile as it does the left.Breaking:
trust()takesboundaryas an argument instead ofstepControl$boundary.trustL1()takes the settings astrust()does:ftol,mtol,gtol,xtolandrminintolControl,thetaMax(wastheta.max) instepControl, andparupper,parlowerandboundaryafteriterlim; a flat name is refused with the list it moved to, anditerlimdefaults to 1000.The
check()of adistributedComputing()job counts a task whose process remains as a zombie as finished, as in a container whose init does not reap.distributedComputing(slurm = TRUE)reads the job ID ofsbatchalso when the build on the login node prints before it.plotCombined(aesthetics = )replaces a default aesthetic also under the other spelling, such ascolourforcolor.wide2long()of a matrix builds the data frame without a row-name warning.
dMod2 0.13.0
Breaking:
steadyStates()has one solver, the former version"1.4": every unknown is solved from a combination of balances, so every result is a ratio of positive sums. The versions"1.0"to"1.3"and the argumentsversion,sparsifyLevel,outputFormat,positiveandbranchesare gone;testSteadyis"fast"or"skip".Breaking: the options are named
dMod2.*:dMod2.cores,dMod2.outdir,dMod2.batch.checkanddMod2.compile.cmdlimit; thedMod.*names are no longer read.dMod.quietanddMod.sym.<name>are gone:suppressPackageStartupMessages()silences the startup message, andSYMIDENT_<NAME>sets a switch of symident.?dMod2lists the options and environment variables.The solver options of
Xs()andXf()on thecppDEandSundialsbackends takemaxOrder, an upper bound on the order of the multistep methods, andstald, stability limit detection for"bdf".Breaking:
distributedComputing()is rebuilt and takes overrunbg();runbg()andprofileParsPerNode()are removed. The code runs once per task:tasksis a number, a list or a data frame, and the code reads the element or row astaskand the position astaskId, and the cores it may use ascores. Withoutslurmthe tasks run as detached background processes on"localhost", without ssh, or on machines reached by ssh, one after the other per machine and each with the machine’s cores: thosemachinenames, as inc(server1 = 20, server2 = 10), or the free cores of the machine, and never more than are free. Withslurm = TRUEthey form an array job with the coresmachinenames, submitted through the job script template of the login node, with{{ }}fields.inputis taken from the calling environment, every task gets the seedseed + taskId,recoverneeds only thejobname, and the job gainsterminate();check()returnsTRUEonce no task runs any more and warns about failed tasks.cores,nRep,varValues,partition,nodes,sshPasswd,customFolders,returnAll,resetSeedsandpurgeLocalare gone.demo("BA_transport")sends the multistarts this way, andexamples/distributedComputing.mddescribes it.slurmTemplate()sets up the job script template of a SLURM cluster once per login node, kept across sessions, from a job script of the cluster or from the one dMod2 ships for the bwForCluster Helix.mstrust()draws every random start, those of retries included, before it spreads the fits overcores, soset.seed()reproduces a run whatevercores.unique()on a parframe returns the rows with distinct values sorted by value, also for a parframe not sorted by value; rows are selected withsubset()first. dMod2 needs ggplot2 3.5.0.rref()no longer takesverbose, which it did not use.detectFreeCores()names the values by machine and reaches"localhost"without ssh.symmetryDetection(unknownInputs = )declares unknown functions of time; an exact direction lists the change of each input asinputChange. Needs symident 0.12.0.Loading dMod2 no longer requires symident in the Python environment; symmetryDetection() and symmetryReduction() require it on first use, so a symident that cannot be resolved leaves the code generation of models intact.
Breaking:
getElements(),blockdiagSymb(),getLinVars(),long2wide(),lsdMod(),compare(),forcingsSymb()anddot()are removed, as is thecharactermethod ofreduceReplicates();reduceReplicates(read.csv(file))replaces it, and openxlsx and purrr are no longer suggested.progressBar()is no longer exported.Breaking: a dMod function refuses a named argument it does not take, more unnamed arguments than it has inputs and a missing input, so
x(times, pars, condition = "C1")is an error instead of a prediction for all conditions.Xs()andXf()refuse arguments they do not take.Breaking: the subset expressions of
plotPars(),plotValues()andplotArray()come right after the data,tol,direction,covtableandnSimafter them;covtabledefaults toNULL, and the subset applies with and without it.plotArray()drawsnSimtrajectories evenly spaced from the optimum, at most one per profile point, grouped by parameter set.Xd()applies the chain rule of a parameter transformation and differentiates by the free parameters only; a missing grid parameter is an error.predict()on a parframe labels each prediction with the row it comes from, also for a parframe not sorted by value, and adds a condition grid with one covariate;plotResiduals()uses the row of each fit.addReaction()reads any numeric coefficient, such as3/2*A,(2)*Aor2*3*A, and refuses a term that is nocoefficient*species, a reaction without species and a state namedRateorDescription.getReactions()writes the coefficients as they are.subset()of an eqnlist takes%in%on a vector as base R does.rref()sets entries belowtolto zero and returns the pivots as an integer vector;nullZ()passestolon and returns the identity for a matrix without pivots. Conserved quantities have no rounding residues.lloq = NAin data means no limit of quantification.as.datalist()takes data without a condition or covariate column, as one condition"1", tibbles and data.tables. Renaming a datalist renames theconditioncolumn,subset()of a datalist keeps the condition grid, andcovariates()of a data frame returns a data frame for any number of covariates.reduceReplicates()names conditions by the levels of factor columns.profile()checkswhichPar,stepControlandalgoControl, names a failed profile with the error, reports an objective error that ended a side and singular Hessians once per profile, and returns the optimum alone when no step is accepted. Each path step solves the linear system directly and takes the pseudoinverse only for an ill-conditioned one.confint()takes a profile without adatacolumn throughval.column = "value".mstrust()takes an anonymoussamplefunor one with a long name, passes the arguments of an optimizer other thantrust(), refusesfits < 1, and writes one log entry per fit also from PSOCK workers;load.parlist()reads the fits in the order of their numbers.mstrust()andprofile()share one parallel backend.A scaled objective
a %.*% objkeeps an absent gradient or Hessian absent and needs a finite scalara.On the
deSolvebackend,Xs()andXf()return the requested times only, warn when the solver stops early, name missing parameters, andXs()checksnamesand refuses an odemodel without sensitivities.[on a parframe keeps a single column as a parframe and selects columns by a single index, as for a data frame;as.parvec()of a parframe checksindex;parframe()takes as parameters the columns that are neither meta names nor objective attributes.summary()andplot()of a parlist skip aborted fits,summary()also takes an empty parlist and fits without convergence flag, andc()of parlists concatenates.eqnvec(),parvec()andprdlist()name unnamed entries by their position; a parvec withNAprints;wide2long()refuses duplicated names.plotPaths()andplotPathsMulti()build their paths in one pass;plotPathsMulti()normalizes each path to the range -1 to 1 and colors thenParslargest paths, the others in “Others”.plotPars()detects steps on a frame in any order and names the columnstep. A layer added toplotCombined()uses the data of the layer.coordTransform()propagates errors only wheresigmais given.plotFluxes()takes any number of fluxes.wide2long(),lbind()andcombine()bind through data.table, also the data frames of predictions with many conditions.write.eqnlist()andas.eventlist()handle empty lists;is.eqnlist()checks that the columns of the stoichiometric matrix are the states.Pexpl()marks an output as fixed only when it depends on no varying input, andPimpl()keeps the rows of every solved state, so an output whose first derivative vanishes at the evaluation point keeps the second derivative.Pimpl()treats a species that no reaction changes, such as a catalyst, as a constant state, not as zero.In a sum of objectives,
datapointL2()finds the predictions of everynormL2()term, also behind a prior or a term thatconditionsskips.obj + NULLreturnsobj; adding anything else that is not an objfn is an error.constraintL2()and the other priors apply a namedsigmato the parameter it names and refuse asigmawithout an entry for a parameter ofmu.trustL1(minimize = FALSE)subtracts the penalty from the objective it maximizes.evalConditionResidual()passesfixedparameters to the error model also without sensitivities.odemodel(deriv = FALSE)builds no derivatives, whateverderivMode.define()andinsert()refuseconditionMatchfor a trafo without a condition tree.eqnlist()takescompartmentswithoutcompartmentOf, with every state indefaultComp, and refusescompartmentOfwithout the compartments.c()of eqnlists keeps the layout of an eqnlist without reactions and the custom totals, andsubset()returns an empty eqnlist when no reaction matches.log10Transform()keeps names that sympy reads as constants, such asEandI.format.eqnvec()keeps powers and numbers such as1e-3whole.as.eqnvec()refuses empty and duplicated names.lbind()andas.data.frame()of a datalist fill a column that some conditions lack withNA.c()of datalists returns classlistas well and refuses a condition named twice.as.datalist()refuses covariate values whose condition names coincide.subset()of a parframe and the subsets ofplotPars(),plotValues()andplotProfile()take several expressions and see the frame of the caller.as.parframe()of a parlist fills a parameter that some fits lack withNA, andc()appends a single fit to a parlist.plotProfile(parlist = )draws the profiled parameters only,plotProfilesAndPaths()draws the total profile,plot()of a prdframe takes a data frame, andcoordTransform()keeps the order of the rows.modelname<-assigns a vector of names condition by condition and takesconditions;getParameters(conditions = )of a function for every condition returns the parameters of that condition.The code that dMod 1 contributors other than the authors wrote is reimplemented from the documented behavior: the print methods of eqnvec, eqnlist, objlist and parvec,
summary(),plot()andas.parframe()of a parlist,fitErrorModel(),reduceReplicates(), the argument routing and fit log ofmstrust(),Xd(),define(),insert(),conservedQuantities(), the datalist methods and the prediction, data, flux, residual and array plots. With the oldsteadyStates()versions gone,DESCRIPTIONlists the two authors only.Xd()takes a state with a single grid point as constant;plotFluxes()labels an unnamed flux by the flux expression also when others are named;eqnlist()takes a plain vector as a one-column stoichiometric matrix;reduceReplicates()groups by the exact times instead of times rounded to seven digits.In a nested sum of objectives, a term without conditions is evaluated for any requested conditions, as in a flat sum.
summary()of a parlist heads the table “Best and worst fit”; the messages ofas.parvec()on an unconverged fit,as.eqnvec()on unparsable equations andsteadyStates()on namedgivenCQsare reworded.
dMod2 0.12.7
-
loadDLL()also loads the shared objects of a model’s auxiliary sources, such as the influx function ofPimpl(), somstrust()andprofile()with a condition axis run on PSOCK workers also for models compiled source by source. -
trust()andtrustL1()append the objective’s error message toparinit not feasible: objfun failed. -
define(),insert()andrepar()ontrafo = NULLmap each left-hand side to the right-hand side, not to itself.
dMod2 0.12.6
-
controls()on an objective also reaches the functions it evaluates: the prediction and error model of eachnormL2()term and the parameter transformation of anobjfn * parfn. Solver tolerances and other controls can be changed through the objective alone.conditionrestricts the lookup as for anfn. - An unknown entry of
options,optionsSensoroptionsReverseofXs()andXf()is an error, also when set later withcontrols(). -
Y()names a state the prediction does not return, e.g. after the controlnamesofXs()left it out. - A failed batch solve names the conditions that did not complete.
-
plotValues()shows unconverged fits in red with a legend entry of their own instead of a caption.
dMod2 0.12.5
-
plotValues()colors converged fits by their iterations on the dMod ramp and draws unconverged ones in red, with a caption only when there are any. WithpseudoLog = TRUE, a range within one decade gets breaks at 1-2-5 or finer. - The demo
KokMSB2020shows the model scheme of the publication and the statistics of 200 fits, which ship ininst/extdata/kok/.
dMod2 0.12.4
-
symmetryDetection()andsymmetryReduction()need symident 0.11.0. A direction checked without an error bound has level"checked", andinfo$assumptionslists the declared domain and the declared starts of the switches, with the error bound. -
symmetryReduction()names the claims of a section that are not proven underblocks[[i]]$unproven, with level"open", and listsassumptions; the level"assumed",blocks[[i]]$assumptionsand the argumentverboseare removed. A section on a face holdsfaceWhyandfaceLevel; a resting state checked only at random points of the face makes the block"checked". - In the blocks of
symmetryReduction(),newParameters,solvedDomainandchoicesreplacesurvivorMeaning,carrierDomainandadmissible. -
trust()takesphases, a list of phases, each with a separatehessianMethod,iterlim,sweepandqnControl, run in turn and cycled through for up toswitcheshandovers. A phase that uses up theiterlimof the phase hands over like a soft stop.fallbackControlis removed:fallbackControl = list(hessianMethod = "sr1", limit = 3, iterlim = 200)isphases = list(list(hessianMethod = "gn"), list(hessianMethod = "sr1", iterlim = 200)), switches = 3. A run withoutphasesis unchanged. - The result of
trust()hasphaseIterations, the iterations of each phase run in run order, and withphasesthe sweeps of the phases asphaseSweepin place offallbackSweep.as.parframe()adds a columniterations.<phase>per phase. - Each run of a quasi-Newton phase has a separate allowance of reseeds by
qnControl$hessianReseed = "stall";nReseedcounts over the run. -
mstrust(cores = c(fits = , conditions = ))runs both axes as given, each capped at the cores available, and records that layout inattr(, "run")$cores. -
mstrust()andprofile()stop the cluster of a conditions axis and restoreoptions(dMod.cores)on exit, on every platform. - The cores available are those of the R process,
parallelly::availableCores(), which follows the CPU affinity and a SLURM or PBS allocation. dMod2 imports parallelly. - A sum of objective functions keeps the
compileInfoof the terms, soloadDLL()on it searches the directories the sources of the terms were compiled in.
dMod2 0.12.2
-
trust()gainsfallbackControl, the settings of the fallback phase:hessianMethod(default"none"),limit,iterlim(per fallback phase),sweepandqnControl. Withsweep = NULL, the default, the fallback phase evaluates the objective backwards when the chain can.hessianFallback,fallbackLimitandparscaleare removed. -
trust()defaults toiterlim = 1000, counted over all phases. - The deprecated argument names and aliases are removed, among them
attr.name,opt.BLOQ,obj.attributes,sort.by,split.by,keep.covariates,rank.tol,attach.input,keep.root,optionsOde,start1stfromCenter,fterm,mterm,stepControl$theta.max, thecontrolsPTCentriesrtolandatol, thecoresofnormL2()andreadPetabYaml(),readPetabTables().repar(expr, trafo)is an error. -
mstrust()dropshessianfrom every fit and recordselapsed, the wall time of each fit, and the attribute"run"with the start time, total wall time, cores, optimizer, sampler, their arguments and the package versions.as.parframe()adds the columnelapsedand keeps"run". -
vcov()takes an evaluation of an objective function,vcov(obj(pars)), withfixedfor parameters held at a bound.vcov()on a fit without Hessian is an error instead of a matrix ofNA. - The
.Rfiles ofmstrust(cautiousMode = TRUE)restore the fits exactly.
dMod2 0.12.1
- Needs symident 0.10.1.
- When symident needs msolve and finds none,
symmetryDetection()andsymmetryReduction()ask in an interactive session whether to build it into the symident cache, on Windows with Rtools, and then repeat the call.
dMod2 0.12.0
- Needs cppDE 0.13.0 and symident 0.10.0.
-
getSymbols()andreplaceSymbols()are dMod2’s own, no longer re-exported from cOde, which is needed for the deSolve backend only.replaceSymbols()brackets a replacement that is not a single operand, replaces variables only, not function or argument names, and keeps the spacing. -
piis the number in equations, as in cppDE, andgetSymbols()does not list it. -
symmetryDetection()gainsregimes, the regimes an experiment visits in a model with switches, overall or per condition. - A direction of
symmetryDetection()has alevel("exact","verified"or"open") in place ofcertified, andstateComponents.infogainsrankStatus,proof,bound,gapCertified,limits,errorsandbranches. -
reconstControl()gainshomotopyDegree,degreeCapMax,exactProof,exactWorkCapandseed;NULL, the default, keeps the value of symident. -
symmetryReduction()stops at a direction of level"open"unlessallowOpen = TRUE. It gainsworkCap,timeoutdefaults toInf, andcheck = TRUEruns the detection again on the reduced model. The result gainslevel,limitsandchecks, and each block alevel. -
plotValues()draws the objective values on a linear scale, not their distance to the best fit on a pseudo-log scale;pseudoLog = TRUEswitches to a pseudo-log10 scale. - The data set
kokand the demoKokMSB2020. The Bachmann, Boehm, bile acid and Hodgkin-Huxley scripts are demos as well,demo(package = "dMod2")lists them; the tutorials left ininst/examplesfrom dMod and the R2C templates ininst/templatesare removed, and the gradient comparisons moved tobench/gradient. -
bench/andbenchmarks/are one directory,bench/, by topic:harness/(the PEtab benchmark suite),gradient/,hessian/,symmetry/,multipleShooting/andnumSteady/.
dMod2 0.11.4
- symident and python-libsbml are found in
~/.virtualenvs/r-reticulatetoo, installed on first use. -
summary(x, detailed = TRUE)on asymmetryReduction()result explains each section. Needs symident 0.9.3.
dMod2 0.11.3
- New
trustL1(): the trust region oftrust()with an L1 penalty on chosen parameters around reference valuesmu, one-sided withone.sided.gatekeeps a parameter on or above the kink of the penalty, so it can reach the reference exactly, andfusepenalizes the pairwise differences within blocks, whose members move as one while equal. The penalized step runs in a C++ kernel.
dMod2 0.11.2
-
symmetryDetection()andsymmetryReduction()install symident from PyPI on first use; underRETICULATE_PYTHON,pip install symident.
dMod2 0.11.1
-
distributedComputing()runs zstd as a separate pipe stage and moves the uploaded files one by one, so the upload and the collection of results run on macOS.
dMod2 0.11.0
- Breaking:
Xs()on cppDE takesrefineandgradtolinoptionsReverse;flooris gone, and so is the weighting of the backward grid by the previous evaluation’s adjoint.refine = TRUEholds each step of the backward sweep to the error test of the CVODES backward problem underabstolandreltol, throughcppDE::adjointControl(refine = TRUE), andgradtolis then the absolute tolerance on each step’s share of the gradient. The reverse value pass takes the grid of a value solve. - New
symmetryDetection(),reconstControl()andsymmetryReduction(): structural non-identifiabilities of an ODE model, as generators of the symmetries of the model, and the parameter transformation that removes them. The computation runs in the Python package symident through reticulate, which installs it on first use from https://github.com/dModverse/symident; R arguments and fields are camelCase,print()andsummary()are the reports of symident. symident’s switches are read fromSYMIDENT_*and from the optionsdMod.sym.*. msolve, for coupled steady states, comes fromsymident.install_msolve()orSYMIDENT_MSOLVE. - reticulate no longer provisions symengine.
-
Xs()on cppDE and Sundials stops on a failed solve (onFailure = "stop"), asXf()does; a fit takes the error as a rejected step. -
Xs()on cppDE:optionsSens = list(sensErrCon = FALSE)takes the sensitivities out of the error test. -
odemodel(backend = "Sundials", derivMode = "reverse")takes events: the reverse objective takes the adjoint and the gradient through each jump. - Reverse objectives run their solves through prepared batch handles, evaluate the error model batched and keep the data-to-prediction indices between evaluations. Under second order a transformation that no tangent reaches skips the second derivatives of that transformation.
-
normL2()with one condition evaluates the error model without derivatives when none are requested. -
importPEtab()gainssparse, which pins the sparse (KLU) or dense linear solver of the cppDE and Sundials backends. -
benchmarks/, outside the built package: value, forward and reverse gradients of PEtab benchmark problems by tier (run-benchmarks.R --tier tiny|medium|full), with the scripts ofinst/benchmarks/underbenchmarks/scripts/. - A sum of objectives keeps the
sweepattribute the terms agree on, so a reverse objective with a prior says it was evaluated in reverse. -
constraintL1()andconstraintL2()are S3 generics; the default methods are the priors on named parameters. - The option
dMod.outdirsets whereodemodel(),P(),Pimpl(),Y()and the PEtab import write generated sources and shared objects; unset, it is the working directory. -
getSymbols()andreplaceSymbols()are reexported from cOde. - Breaking:
Xs()takes the solver options asoptions, which applies to every solve, andoptionsSens, which holds only the entries that overrideoptionsfor the solves with sensitivities.Xf()andimportPEtab()takeoptionsas well, and the controls are namedoptions,optionsSensandoptionsReverse.optionsOdeis still accepted as an argument and bycontrols(), with a deprecation warning. On deSolve the default methods stay"lsoda"and, for the solves with sensitivities,"lsodes". -
Xs()on cppDE warns about an unknown entry ofoptionsReverse, given to the constructor or set throughcontrols(). - The solver option for the limit of consecutive rejected steps is
maxattempts, as in cppDE. - Fix:
constraintL2() * P()takesfixed, and with ittrust(fixed = )andprofile()on such priors. - Fix:
Xt()returns the sensitivities by the outer parameters, sog * Xt() * phas derivatives andnormL2()on it takesfixed. - Fix:
Y()differentiates by the observation and error parameters also when no transformation precedes the prediction, those that are not parameters ofxincluded. - Fix:
normL2()takes an error model whose parameters are all fixed. - Fix:
as.datalist()stores asigmaorlloqcolumn ofNAalone as numeric. - Fix:
mstrust(cautiousMode = TRUE)removes the.Rdafits of the same run only, not files of that name in the working directory. - Breaking: arguments in dot case are camelCase.
Y()andPexpl()takeattachInput(wasattach.input),Pimpl()keepRoot(waskeep.root); both are also the names of the controls. - Breaking:
normL2(),datapointL2()and theconstraint*()priors takeattrName(wasattr.name), also as control ofdatapointL2();normL2()andevalConditionResidual()takeoptBLOQ(wasopt.BLOQ). - Breaking:
datapointL2()takesparameter(wasvalue), the name of the parameter holding the data value. - Breaking:
as.datalist()takessplitByandkeepCovariates(weresplit.byandkeep.covariates),as.parframe()sortBy(wassort.by),parframe()objAttributes(wasobj.attributes; the attribute name stays the same). - Breaking:
reml()andremlLeverage()takerankTol(wasrank.tol). - Breaking:
trust(stepControl = )takesthetaMax(wastheta.max);mstrust()takesstartFromCenter(wasstart1stfromCenter). - Breaking:
distributedComputing()takesmemPerCore,sshPasswd,varValues,nRep,purgeLocalandcustomFolders(weremem_per_core,ssh_passwd,var_values,no_rep,purge_localandcustom_folders); thepurge()of the job takespurgeLocal. - Breaking:
plotPathsMulti()andplotProfilesAndPaths()takewhichParandnPars(werewhichparsandnpars),plotProfilesAndPaths()ncol(wasncols),plotArray()nSim(wasnsimus),plotFluxes()legendTitle(wasnameFlux),attrs()which(wasatr) andprofileParsPerNode()parsPerNode(wasfits_per_node). - Breaking:
reconstControl()takesminSupportCandCap,perPrimeCapandperPrimeMinPrimes(wereminsupportCandCap,perprimeCapandperprimeMinPrimes). - Breaking:
readPEtabYaml()andreadPEtabTables()replacereadPetabYaml()andreadPetabTables(). An imported problem prints as<PEtab problem ...>. - Breaking:
repar(trafo, expr)takes the transformation first, asdefine()andinsert()do. The orderrepar(expr, trafo)is recognized by an expression in first place. - Breaking:
profile()andvcov()are methods of the generics of stats, which dMod2 no longer masks.profile()dispatches on objective functions and plain R functions, first argumentfitted(wasobjfun).trust()returns a list of classtrustfit, kept bymstrust(), on whichvcov()dispatches, first argumentobject(wasfit); a fit stored before needsclass(fit) <- c("trustfit", "list"). - Breaking: the operands of
+and*on dMod functions, objectives, objlists and datalists are namede1ande2. - The old names above are accepted with a deprecation warning; giving the old and the new name together is an error.
- Breaking:
distributedComputing()submits by default (recover = FALSE). Theget()ofdistributedComputing()andrunbg()returns the results instead of assigningcluster_resultor.runbgOutputin the global environment;runbg(wait = TRUE)returns them too. The former behavior iscluster_result <- job$get(). - Breaking:
steadyStates()writes nothing unlessfileis given; the model for the solver goes to a temporary file. The unused argumentratesis deprecated and ignored, andverbosedefaults toFALSE. - Breaking:
fitErrorModel()plots only withplotting = TRUE;resetWarmStarts()andsymmetryDetection()print only withverbose = TRUE. - Breaking:
symmetryDetection()requiresfandg. -
ggopen()opens the PDF with the viewer of the platform by default:openon macOS,xdg-openon Linux,shell.exec()on Windows. -
trust(parscale = )is deprecated and warns; it still scales the trust region. Fit on log scale instead. -
msParframe()leaves the global random number generator as it was.mstrust()takessamplefunas a function as well as the name of one. -
rref()returns a list namedrrefandpivots; the unused argumentfractionsis deprecated and ignored. - Breaking:
Pimpl(controlsPTC)takes the tolerances asreltolandabstol, ascppDE::ptc()does;rtolandatolare deprecated. -
compile()restoresPKG_*flags set before the call without an error, and leaves nosymbols.rdsin the working directory underR CMD check. -
reconstControl(homotopy = )switches the last reconstruction route of symident, which fits directions still open underequilibrate = TRUEalong lines in parameter space; on by default. - Needs cppDE 0.12.0.
dMod2 0.10.3
- The help pages of the constructors (
odemodel(),Xs(),Xf(),Xd(),Xt(),Y(),P(),Pexpl(),Pimpl(),normL2(),datapointL2(), theconstraint*()priors) and of the function classes are rewritten, with examples forXs(),P(),Pexpl()andPimpl(). -
Xs()andXf()on cppDE and Sundials return the forcings after the states, so observables can contain them, and take forcing names as factor. A forcing holds the first and last value outside the points and may be a single point. -
Xf()on cppDE and Sundials starts states missing fromparsat 0. -
datapointL2()returns anobjlist. -
constraintL2()stops on asigmathat mixes numbers and parameter names. -
normL2()names the data conditionsxdoes not have. -
plotValues()puts the breaks at 0 and at the decades from 10 on and leaves the limits of the y axis free. - Needs cppDE 0.11.3.
dMod2 0.10.2
-
runbg()anddistributedComputing()withcompile = TRUEtake SUNDIALS’ include path, and MPI’s if that SUNDIALS was built with it, from the cppDE installed on the remote machine instead of the submitting one. A model using SUNDIALS’ LAPACK dense solver links it there too, and the build stops with a message if the remote SUNDIALS lacks it.
dMod2 0.10.1
-
Pimpl()draws the random starts uniformly overstartRange = c(-5, 5)onstartScale, log10 by default and linear ifpositive = FALSE. Each warm-start cache, i.e. each condition in each fit ofmstrust(), draws from a separate stream; the global RNG is read, not advanced.maxitdefaults toceiling(70 * log(n + 1))fornstates (was 400). - Needs cppDE 0.11.2:
ptc()scales a row by the largest partial derivative in that row and builds on macOS.
dMod2 0.10.0
-
normL2()losest0.timesis a vector for all conditions or a list named by condition, and the prediction of a condition starts at the first time of the grid, the data times and thetimesof that condition:times = list(C1 = -10, C2 = 5)is whatt0 = c(C1 = -10, C2 = 5)was. Withouttimesthe grid starts at the first data point, which matters only for a model built withodemodel(..., includeTimeZero = FALSE); with the default the grid holds 0. PEtab start times go throughtimes, in one objective for all conditions. -
Multiple shooting.
normL2(data, g * x * p, multipleShootingControl = TRUE), or a list of settings, makestrust()andmstrust()fit by Bock’s generalized Gauss-Newton method. The time axis is cut into segments with node values of their own; continuity is a constraint, linearized and eliminated at every iterate (condensing), so the subproblem keeps the single-shooting size and box bounds apply unchanged. At convergence the result is a stationary point of the single-shooting objective, which the objective still is when called as a function. The ODE model needsodemodel(..., includeTimeZero = FALSE);profile()re-optimizes by single shooting. - The trust region bounds parameters and node values together. Steps are accepted by a filter or an l2 merit function (
stepControl$acceptance), with a second-order correction (stepControl$soc) and a gap tolerance (tolControl$ctol). -
stepControl$anneal(default) first penalizes the gaps,f + w ||c||^2withwrising tenfold per stage, then hands over to the exact method. A stage ends once a step gains less than a thousandth; the annealing ends early where the penalty dominates and a stage no longer closes the gaps. -
nodes = "auto"(default) starts from ten segments per condition, or one per half oscillation of the data where that is more, and cuts a segment where the propagation matrix of the segment grows by more thangrowth, where the segment misses the data by more thanmisfitand by twice the median of the condition, or where the solve of the segment fails. A misfit everywhere is left to the parameters, and each half of a cut keepsminPointsdata points, by default one more than the states. Unobserved node values start from a run synchronized to the data.chartsputs node values on a log10, linear or angle scale per state; the gap of an angle is taken modulo 2 pi. The scale of an unobserved linear state is the largest range it covers within one segment.hessianMethod = "bfgs"or"sr1"keeps one quasi-Newton block per segment. - The cost of an evaluation is linear in the number of segments: segment parameters are built per condition, the annealing model is assembled in one pass, and the values at new nodes come from one batched solve.
fit$multipleShooting$cutscounts the cuts by growth, misfit and failed solve. -
c()of one parameter vector, alone or besideNULLor an empty one, as every prediction builds theparameters, skips the list machinery. - Methods of the Freiburg group (Bock; Horbelt, Timmer and Voss 2002; Peifer and Timmer 2007; Voss, Timmer and Kurths 2004), off by default:
stepControl$acceptance = "natural"(damped Gauss-Newton on the natural level function, needs a fixed sigma),stepControl$twoPhase(parameters first, then nodes),stepControl$regularise,stepControl$restore(restoration phase of the filter),init = "spline",minPoints,nodes = "transitions"(a node just before each fast change of the data) andbreaks(nodes without continuity). - Spiking data need tight integrator tolerances (1e-10); at 1e-8 the objective is too noisy far from the optimum and the trust region collapses.
- The objective returns the weighted residuals of each segment and their Jacobian on request (
residuals = TRUE). A trial point after a rejected step is evaluated without sensitivities. - The reverse walk takes several first-order seeds at once, which
Xs()answers in one backward solve. Checkpoints serve any number of backward sweeps. - New benches
bench/multipleShooting_preBotC.Randbench/multipleShooting_macrospin.R.
dMod2 0.9.2
-
Pimpl()runs a multistart when the warm starts and the initial guess fail:controlsPTC(nStarts = 20, startSd = 2, seed = 1), log-normal around the guess, from a fixed seed and without touching the global RNG. If every start fails it is an error. -
plotValues()draws the objective values minus the best one on a pseudo-log10 scale, linear below 1;"data"holds the distance indelta.
dMod2 0.9.1
-
exportPEtab()reads the parameter scale offp: a parameter entering only asexp(X)is written withparameterScale = log, one entering only as10^(X)orexp10(X)withlog10, with linear nominal values and bounds five decades around them.parameterScale = NULLis the new default. v2 writes the linear values. -
exportPEtab()writes no self-referencing files for a trafo likeA ~ exp(A). An outer parameter named like a state goes out asinit_<state>and the condition table sets the species to it; one named like an inner parameter keeps the name under a pure scale wrap and becomes<name>_outerotherwise. Symbolic initial values go to the condition table instead of SBML<initialAssignment>. An export with an assignment that would still refer to the target of that assignment stops with an error. -
exportPEtabObject()to v1 keeps preequilibration conditions in the condition table, leaves condition targets and compartment sizes out of the parameter table, writes observables in a v2 noise formula as their formula, and refuses condition switches during a simulation, which v1 cannot hold. A v2 experiment names no condition where the table has none. -
exportPEtabObject()to v1 moves an expression that sets a species in every condition into an SBML initial assignment and warns about per-condition expressions, which v1 does not allow; start times after 0 stop the export. Measurements name their conditions by id, as the condition table does. -
exportPEtabObject()to v1 keeps the SBML constants of an imported problem in the SBML, as v2 does, so they keep their role in a preequilibration. -
exportPEtabObject()declares condition targets and compartment sizes that nothing else states, with the SBML default recorded at import. -
exportPEtabObject()writes a single measured sigma per observable as the noise formula of that observable instead of per-row noise parameters. -
exportPEtabObject()translates priors between the versions: v1 spells the log familieslogNormal/logLaplace, and a v1 prior on the parameter scale goes to v2 as the matching prior of the linear parameter.importPEtab()reads the v1 spellings and truncates a prior on the parameter scale at the bounds on that scale. -
importSbml()substitutes the initial assignment of a constant parameter wherever the parameter appears, with species at their initial values, so a condition that sets the source parameter reaches the rates. -
repar(),insert()anddefine()keep a trailing underscore in an identifier. -
Y()returns a NaN observable instead of stopping, andnormL2()stops only on a NaN at a data point. -
importPEtab(derivMode = c("forward", "reverse"))builds the observation, error model and parameter transformation for the reverse sweep as well, soobj(sweep = "reverse")runs. -
exportSbml()declares species that enter a rate without being consumed or produced as modifiers, as SBML requires, and stops on a compartment sized by the symbol of that compartment without a value.
dMod2 0.9.0
-
Pimpl()solves steady states by pseudo-transient continuation: implicit Euler steps under local error control that turn into Newton steps near the root. It follows the flow to a stable steady state and checks the eigenvalues on the conservation manifold;flow = FALSEreturns any regular root of plain equations. The iteration runs in C++,cppDE::ptc(). -
Pimpl()keeps every species and adds the conservation rowsC x = Tinstead of eliminating pivot species. Iterates stay positive and on the manifold. States without influx at the given parameter values are 0. -
Pimpl()starts deterministically: the nearest kept root of the condition corrected by the sensitivities of that root, then the initial guess. Conditions with identical inputs are solved once. A failed solve is an error. -
Pimpl():controlsPTCreplacescontrolsMSandcontrolsNleqslv,expressInTotalsis gone. nleqslv is no longer a dependency. -
Pequil()is removed.P()builds aneqnlistwithPimpl();method = "equilibrate"is gone. -
importPEtab()computes preequilibration withPimpl(). Events do not act during preequilibration (PEtab v2 case 0023). -
importPEtab(): species a preequilibration cannot move keep their initial values. They take part only in reactions idled by SBML constants at 0 or by species that start and stay at 0, and the steady-state equations leave them undetermined.
dMod2 0.8.4
-
steadyStates()1.3 and 1.4 detect structurally zero clusters that span compartments, such as a ligand in the medium bound by a receptor in the cell. The sink-cluster test runs in amounts, over reactions rather than the rows per volume ratio the backend reads. As in 0.8.3, a conserved moiety in the support of the test stays nonzero.
dMod2 0.8.3
- Structurally zero states: only species that drain into a leaking reaction are zero; a conserved moiety listed before a leaking cluster stays nonzero.
dMod2 0.8.2
-
steadyStates(version = "1.4")prints the resolved expressions through sympy, as 1.3 does: no redundant brackets from the substitution, nothing expanded. -
steadyStates(version = "1.4", solveQuadratic = TRUE): a state whose own balance, denominators cleared, is quadratic with positive production and quadratic consumption takes the unique positive root, tried before any rate constant. A root that would take a balance another unknown needs is dropped for the next attempt. -
steadyStates(version = "1.4", givenCQs = ): each conserved quantity keeps one state free, the first one whose balance can be spent elsewhere.customTotals()reach it. -
steadyStates(version = "1.4")never solves for a rate constant whose fluxes all contain aneglected symbol, which would divide by that symbol. -
steadyStates(version = "1.4")prints one line per attempt instead of the intermediate expressions, notes after the summary, and on failure the balances left. -
steadyStates()handles species named like sympy objects (Ci,E,S,Q,gamma).
dMod2 0.8.1
-
steadyStates(version = "1.4"): a new core on the same interface. Balances are linear forms over the flux terms, and each unknown comes from a combination of balances a linear program finds, so every solution is a ratio of positive sums. Where no single unknown is left, one side of a balance shares the sum of that side by new flux ratiosr_*. Needspositive = TRUE; volumes are never unknowns, andsolveQuadratic,branchesandgivenCQsdo not apply. -
steadyStates(verbose = ):TRUE(default) prints a few progress lines and the result,FALSEthe result only,"full"every step. -
steadyStates()1.3 solves linear balances directly instead of bysolve(), reads signs off the expression tree after a numeric screen, and searches a block balance by balance when no pivot combination is positive. -
steadyStates()solves a strongly connected block of states jointly where no single balance stays positive, e.g. receptors recycling through endosomes. -
steadyStates()solves every rate constant at most once. A symbol defined twice, by itself or in a cycle is an error. -
steadyStates()factors out common terms instead of canceling the resolved expressions. -
steadyStates(testSteady = "fast")checks mod p only. A residual it cannot evaluate is an error that names the reason, not a fallback to the symbolic test. -
normL2(t0 = )takes one start per condition, named by condition. -
Pexpl()andY()buildderivMode = "forward"by default and accept"forward-reverse", which the reverse sweep withderiv2 = TRUEneeds. -
controls()reaches every option an object uses at run time, andcontrols<-changes it for the next call.Pimpl()(keep.root,controlsMS,controlsNleqslv) andPexpl()(attach.input) have controls;Pequil()readskeep.rootandattach.inputfrom them, and the memo ofPequil()answers only calls made with the same controls.Xs()andXf()merge the solver defaults at each call, so replacingoptionsOdekeeps the options it does not name. The accessor walksg * x * p, the summands of a sum (attributeterms) and the objective inside%.*%andobjfn * parfn;condition = NULLsets every condition, and an unknown name or condition is an error. -
mstrust()routes the arguments by the formals ofoptmethodinstead of those oftrust(), and does not passcautiousModeto the objective. - A prediction the solver cut short is an error in
normL2()that names the time the solver reached, whichtrust()takes as a failed step.Pexpl(attach.input = TRUE)gives the inputs it passes through their forward derivatives, so the forward gradient and Hessian along them are complete; inputs infixedare handed on as constants. The name clash check ofmstrust()measures the intersection. - Requires cppDE 0.10.2.
dMod2 0.8.0
-
Reverse mode.
obj(pars, sweep = "reverse")walksnormL2 -> Y -> Xs -> Pbackwards in one sweep, at a cost that does not grow with the number of parameters; withderiv2 = TRUEit returns the exact Hessian at a cost linear in it. Needsodemodel(..., derivMode = c("forward", "reverse")), or"forward-reverse"for second order;backend = "Sundials"uses the CVODES adjoint, andimportPEtab(backend = "Sundials")imports onto it. The reverse gradient belongs to the trajectory of the value solve and reuses the checkpoints of that solve;Xs(optionsReverse = list(gradtol = ))weights the backward step size. -
Derivative arguments.
deriv,hessian,deriv2andsweepeach ask for one thing, andcurvatureis gone.derivModenames the direction at build time inodemodel(),Y(),Pexpl()andimportPEtab();reverse = TRUEand"dual"are errors."symbolic"is gone, so transformation and observation functions evaluate only aftercompile(). -
Optimization.
trust()asks per evaluation for a value, a gradient, a Gauss-Newton or an exact Hessian.qnControl$hessianInit = "exact"seeds a quasi-Newton run,hessianReseed = "stall"fetches a fresh Hessian when it stalls, andhessianMethod = "exact"is a Newton run. - Requires cppDE 0.10.0 and follows the cppDE names:
tangent,hessian,cotangentandcurvature, andcppFUN()forfunCpp(). -
distributedComputing()andrunbg()gainlibs, library paths put in front on the remote side. -
compile()reports the toolchain and reused objects throughmessage()rather thancat(), sosuppressMessages()silences it. -
Bug fixes. A summed objective keeps the curvature of every term.
trust()accepts an objective that declines a Hessian. A backward solve without an answer is an error instead of a zero gradient. A PEtab prior honorshessian = FALSE. The batched backward path propagates more than one direction.compile()stays within the 8191-character command line of Windows. - New examples
inst/examples/example_ReverseAD.R,example_AdjointComparison.Randexample_BachmannReverse.R; the tests compile the models of each file jointly.
dMod2 0.7.5
-
runbg(compile = TRUE)builds on Debian and Ubuntu machines: the generated build script asks the remote R forR.home("include"), ascompile()does locally. -
runbg(compile = TRUE)compiles in parallel: the core count of the build ignores the OpenMP variables.runbg()also gainsbuildCoresandbuildBundle, asdistributedComputing()has.
dMod2 0.7.4
- A prepared ODE batch handle does not outlive the shared object it was resolved from: the cache of
Xs()checks that the object is loaded,modelname<-drops it, and the rename loop inrunbg()anddistributedComputing()covers objectives. - Needs cppDE 0.9.5, where a Windows install detects OpenMP, so a batched solve runs in parallel there.
dMod2 0.7.3
- SBML and PEtab import work in a fresh session:
.dmod_libsbml_python()initializes Python before it readsreticulate::py_exe()and rejects an empty path. - A test covers the interpreter resolution itself, outside the guard
.libsbml_works(), which turns any error into a skip.
dMod2 0.7.2
-
trust()reports the iterate the run reached, also where the run ends onfvalue,preddiff,stepor the iteration limit:argument,value,gradient,hessianandatBound, and with themvcov(),confint()and profiles, belong to the last accepted point. -
trust()takeshessianFallbackandfallbackLimit. The fallback takes over at the first value, model, step or stagnation stop instead of ending the run;fallbackLimitabove one alternates back to the primary source at the next such stop, re-seeding a Gauss-Newton phase from a fresh Hessian at the cost of one evaluation.hessianMethod = "hybrid"is gone, not deprecated: a run is a method and, optionally, a fallback, and no pair has a separate name."hybrid"corresponds to"gn"withhessianFallback = "bfgs", andtrust()says so when it is passed. -
as.parframe()includesnSwitch, the number of Hessian source handovers, so a multi-start can be scored on them. -
trustL1()is gone; the L1 penalty, the clustering of the penalty and the EM layer that uses it are ondevel-EM.constraintL1()stays as the Laplace prior. -
createExample(),exmpextr()andextractExamples()are gone. -
distributedComputing()andrunbg()attachdMod2on the remote machine and nothing else; a job that needs another package attaches it in the job expression. -
trust()groups the arguments intotolControl,qnControlandstepControl. The flatftol,mtol,gtol,xtol,rmin,boundary,theta.max,hessianInit,qnMemoryandqnCautiousare gone, not deprecated;trust()andmstrust()name the control member a moved argument became.trustL1keeps the flat tolerances. -
trust()takesqnControl$qnRejected(SR1 also updates from a rejected trial point, Nocedal and Wright sec. 6.2; defaultTRUEwherever an SR1 phase can occur) andstepControl$nonmonotone(Zhang-Hager acceptance, default0, the monotone rule).
dMod2 0.7.1
-
trust()ends a quasi-Newton run on the gradient.fvalue,preddiffandstepread the prediction of the quadratic model, which during a quasi-Newton phase describes the approximation being built rather than the iterate, so they do not terminate such a run;gradient,stagnationand the radius do. -
trust()takes an interchangeable Hessian source throughhessianMethod."gn"(default) is the Gauss-NewtonJ^T J;"bfgs"and"sr1"maintain a dense quasi-Newton update seeded from it;"hybrid"runs"gn"until it stagnates, then switches to"bfgs"once. The quasi-Newton phase consumes only the gradient. Reflective boundary only. - Objective functions take a call-time
hessianargument. Withhessian = FALSEtheJ^T Jcontraction never runs and the result has aNULLhessian.trust()uses this in the quasi-Newton phase, and it propagates through objective composition. -
trust()reportsnevaland, underblather, thehessianSourceper iteration, so a multi-start can be scored on gradient evaluations. These reachas.parframe()as columns. -
mstrust()drops the deprecatedstudynameargument. Usename. -
compile()builds model shared objects on Windows: the per-source link and the combined-output object compile go throughsystem2(), so the.dlllinks against BLAS, LAPACK and the Sundials solver. - Adds
inst/examples/example_Boehm_JProteomeRes2014.R, which builds the model of that publication and compares the Hessian sources over a multi-start. -
define()andinsert()resolve the values passed through...in the frame they were called from, also inside a function or a knitr chunk. Condition columns and.currentSymbolskeep precedence over the calling frame. The internal names ofinsert()are not visible to those values;.currentTrafoand.currentSymbolsare the documented way to reach the branch being rewritten. -
plotValues()marks a converged fit with a circle and an unconverged one with a triangle, in every plot, and keeps both in the legend. -
subset()on aparframeevaluates the condition against the columns of the frame and then in the frame it was written in, also from inside a function. - Adds the
Optimisationvignette on Hessian sources, seeding and the economics of a multi-start, shipped pre-rendered, withinst/benchmarks/bench_hessianSource.Rbehind the numbers of the vignette. - Attaching the package reports that BLAS is pinned to one thread inside the forked workers of
mstrust()andprofile(), and says so when no thread-control entry point was found and the deadlock is still reachable.options(dMod.quiet = TRUE)suppresses the line. The pin itself is cppDE’s and needs no cooperation here; requires cppDE 0.9.4.
dMod2 0.7.0
- PEtab import and export.
importPEtab()reads a v1 or v2 problem and returns the composedg * x * p, the error model, the objective with the priors and the published parameter vector.exportPEtabObject()writes one back, andexportPEtab()builds a problem from a hand-written dMod model. - SBML import and export through libsbml, reached over reticulate, so a problem that needs neither stays Python-free. Identifiers that R or C++ reserve are renamed throughout, including in the PEtab tables, and the MathML constants
pi,exponentialeandavogadroare folded to their value. -
normL2()returns gradient and Hessian in the order of the parameter vector it was called with, the order in whichtrust()andoptim()read them. -
normL2()reports the sum of squares as achi2attribute. Adding objectives pools the terms sharing anattr.nameand splits the rest intochi2_<attr.name>. -
compile(output = )points the cOde models inside a function object at the batched shared object. - Pre-equilibration takes the conserved moieties from the same reduced network
Pequil()uses, freezes a time dependent input at the start time, and leaves symbols no outer parameter reaches out of the sensitivity system. A failure reports the solver error and the non-finite parameters. -
Y()accepts one observation function per condition and takescores.importPEtab()takescores,deriv,outdir,optionsOdeandoptionsSens, and derives a model name that steps aside for what is already loaded. -
as.data.frame()on a prediction joins the error model by observable rather than by row order. -
wide2long()on an unnamed list numbers the conditions instead of dropping theconditioncolumn, and forwardskeepandna.rm. -
print()on an objective result from aderiv = FALSEcall shows the value alone. - New data set
bachmannwithinst/examples/example_BachmannMSB2011.Rbuilding the model: 25 states, 36 conditions, 113 estimated parameters. - All 31 cases of the PEtab v2 test suite reproduce the published likelihood and survive the export round trip. Of the 35 problems in the Benchmark-Models collection, 33 import, evaluate with derivatives, export and reimport.
dMod2 0.6.5
-
compile(output = )does not link into a shared object the process already holds. A loaded name is replaced by<name>_2with a warning, the rule cppDE’s model constructors apply to their names.
dMod2 0.6.4
- New soft constraints next to
constraintL2():constraintL1()(Laplace),constraintCauchy(),constraintGamma(),constraintExponential(),constraintChisq()andconstraintRayleigh(). Each is the-2 logdensity including the normalization, unlikeconstraintL2(), which is the penalty form, and each applies the chain rule soconstraint * P()is exact. - The multivariate-normal path of
constraintL2()is gone, together with thepenaltySpecplumbing and theplotIndivs()/plotHistIndivs()generics. -
constraintExp2(), an unused box prior inherited from dMod 1.x, is removed.
dMod2 0.6.3
-
normL2()takest0, the time at which initial values take effect. The time grid starts there rather than at 0, so a prediction may begin after 0. - The error model keeps the fixed parameters under
deriv = FALSE. -
Xt()reports the fixed parameters, asXs()does, so an error model can read them off the prediction. -
eqnlist()accepts a model without species, which is a parameter-only problem rather than an error. - The steady-state heuristic evaluates SBML’s
piecewise()and declares a state structurally zero only when the rate of the state vanishes at zero alone.
dMod2 0.6.2
- Reloading the shared object of a model invalidates nothing. cppDE (>= 0.9.2) resolves entry points by name, so the batch handle cached by
Xs(), and every objective built on it, survives an unload and reload. This replaces the symbol-cache flush counter of 0.6.1. -
loadDLL()also searches the directories the sources were generated in, so a model compiled into a temporary folder is found. -
normL2()attachescompileInfo, as*and+do, soloadDLL()andcompile()reach the shared objects of a composed objective.
dMod2 0.6.0
- The core is complete: equations, compiled prediction, observation and parameter transformations, objectives, trust region optimization and profile likelihood. The PEtab, symmetry, mixed effects and Bayesian layers live on separate development branches.
- Test suite over equations, compilation, prediction, objectives, the trust region and profiles.
dMod2 0.5.21
-
plotProfile(),plotPaths()andplotValues()build on one long-format frame; theparlistoverlay is measured against the profile optimum. - dMod palettes,
theme_dMod()and the color scales.
dMod2 0.5.20
-
runbg()runs jobs in the background on a local or remote host. -
distributedComputing()spreads fits and profiles over a cluster.
dMod2 0.5.19
-
reml()estimates the error model from the restricted likelihood, charging each data point with the leverage of that point. -
remlLeverage()reports the hat values, their rank and the effective degrees of freedom per observable.
dMod2 0.5.18
-
mstrust(cores = c(fits = , conditions = ))andprofile(cores = c(pars = , conditions = ))split the two parallel axes. -
profileThreshold()computes the chi-square or finite-sample F threshold thatprofile(),plotProfile()andconfint()share.
dMod2 0.5.17
-
steadyStates()solves for symbolic steady states through sympy.
dMod2 0.5.15
-
Xs()hands every condition tocppDE::solveODEBatch()in one call. -
Y()andP(method = "explicit")evaluate all conditions in one call. -
coresis a call-time argument on every function object and defaults togetOption("dMod.cores", 1L).
dMod2 0.5.14
- Fixed: composing a condition-less function with a multi-condition one kept only the first condition and returned an unnamed result.
dMod2 0.5.13
- The loop over experimental conditions moved from outside a composed chain into the leaves of the chain, so a leaf sees every condition at once and can batch them.
- Predictions and objectives are identical across thread counts.
dMod2 0.5.10
-
normL2()evaluates the data term in a C++ kernel.
dMod2 0.5.8
-
compile()links model sources into one shared object, with compile and link flags taken per file from the backend that produced it. - Objects are reused when source and command are unchanged, recorded in a
.dMod_objectsindex.
dMod2 0.5.7
-
odemodel()generates C++ with first and second order sensitivities. BackendscppDE,SundialsanddeSolve.
dMod2 0.5.6
- An
eventlistis declared onodemodel(), so the sensitivity equations are extended consistently.
dMod2 0.5.5
-
eqnliststores compartments and volumes;assignCompartment()andsetCompartmentVolume()set them. -
conservedQuantities()andgetTotals()report the conserved moieties.