update
will update a model and re-fit.
This allows one to change the data and/or parameters.
# S4 method for hansentree
update(object, data, regimes, sqrt.alpha, sigma, ...)# S4 method for browntree
update(object, data, ...)
update
returns a new fitted-model object of the same class as object
.
fitted model object.
data that replace those used in the original fit.
A vector of codes, one for each node in the tree, specifying the selective regimes hypothesized to have been operative.
Corresponding to each node, enter the code of the regime hypothesized for the branch segment terminating in that node.
For the root node, because it has no branch segment terminating on it, the regime specification is irrelevant.
If there are nchar
quantitative characters, then one can specify a single set of regimes
for all characters or a list of nchar
regime specifications, one for each character.
These are used to initialize the optimization algorithm. The selection strength matrix \(\alpha\) and the random drift variance-covariance matrix \(\sigma^2\) are parameterized by their matrix square roots. Specifically, these initial guesses are each packed into lower-triangular matrices (column by column). The product of this matrix with its transpose is the \(\alpha\) or \(\sigma^2\) matrix. See Details for more information.
Additional arguments replace the corresponding arguments in the original call.