A comprehensive and easy to use R implementation of confirmatory
phylogenetic path analysis as described by Von Hardenberg and Gonzalez-Voyer
Fixed bug that would return the wrong model in some error messages.
Improved reporting of warnings, and a
show_warnings() function has been
Citation info now points to the PeerJ paper.
Citation info now points to the bioRxiv paper.
All modeling functions now completely rely on the
phylolm package, and no
ape. This is a major change, that will possibly change the
outcomes of some of your existing analyses (as can happen when chaning
the modeling package). There are, however, several good reasons to make this
change, which I think make it worth the trouble. Firstly, the package is much
faster for large trees, and this effect is compounded in
one may have to fit a few dozen models. Secondly, I think it is important to
have confidence intervals around the regression coefficients, and those were
not available for
phylolm makes it easy to use
a larger variety of models of evolution, including two versions of OU and
early burst, which can be simply set using the
model parameter. Lastly, the
phyloglm() functions give more uniform results, which makes
it easier to code for situation where you may use both.
phylo_path and all related methods now deal automatically with both
continuous and binary data. All separate binary functions and methods have
disappeared as they are no longer needed. Mixing of binary and continious
data in the same models is now allowed.
The variable order in d-seperation statements now better follows the causal flow of the DAG.
plot() method for
phylopath.summary objects, that shows the weights
and p-values for the different models.
to arguments. The
first allows the user to choose between confidence invervals and standard
errors, the second to order the paths by several methods, and the last two
can be used to select only certain paths.
Plotting methods of causal models now support a manual layout.
Plotting of fitted DAG's now uses edge width instead of color to indicate,
the standardized regression coefficient strength, but this can be reverted
define_model_set() convenience function for building models, that
avoids repeated calls to
DAG() and has an argument to supply paths that are
shared between all your models. It is not needed to specify isolate variables.
Old code using
DAG() continues to work as normal.
Added support for additional arguments passed to
can be helpful, for example, for setting the fitting method to maximum
method = "ML").
The package broke due to an update of
purrr, but has now been fixed
(reported by Christoph Liedtke, @hcliedtke).
The package depends on a recent version of
nlme, but this wasn't specified.
All package versions of dependencies are now defined (reported by
Added support for completely binary models, that are fitted with
phylo_path_binary() to compare models.
choice() are now S3 generics and will handle both continuous
and binary versions. Usage is designed to be as close to the continuous version
est_DAG_binary() powers the binary S3 methods.
All plot functions that used
DiagrammeR now use
ggraph instead. This gives
much more control over the positioning of the nodes, and allows to plot
multiple models at once. Exporting plots also becomes much easier.
You can now plot a list of causal models with
creates a faceted plot where all nodes are kept in the same location, which
makes it easier to spot how models are different.
If there are any
NA values in
data for the variables in
rows are now dropped from
data with a message. Use
na.rm = FALSE to revert
to the old behavior.
When PGLS models fail, an informative error is now returned to the user.
phylo_path() now checks for row.names that line up with the tree tip labels.
If the tree contains surplus species, it gets pruned to size with a message.
This includes cases where species are dropped due to missing values.
citation() now correctly refers to the methods paper by Von Hardenberg &
Gonzalez-Voyer first and the package second.
Fewer models are now fitted when using
phylo_path(), since any duplicated
independence statements are now only fitted once. This leads to a significant
reduction in running time in many cases, especially when many models are
Implemented support for parallel processing in
phylo_path() using the
phylo_path() now shows a progress bar.
New function added (
choice()) that is a very simple wrapper around
est_DAG(). It adds to
average() by allowing for choosing
any model as the final model, and encourages users to not always pick the
lowest CICc model.
Prepared plotting functions for new release of
DiagrammeR, v0.9 now
IMPORTANT: Faulty model averaging has been fixed. This was often introduced due to differences in matrix ordering. Averaging results from versions before 0.2.1 should NOT be trusted.
ape::corBrownian() no longer returns an error.
Averaging is less likely to fail due to errors in
phylo_path() has become more streamlined with functionality moved to other
phylopath object now contains all necessary models and data,
summary() is used to obtain the results table, and
are used to extract and fit the best or average model. See the vignette for
Model averaging for arbitrary models is now possible with
Model averaging now supports both conditional and full model averaging.
Both the old
est_DAG() and the new
average_DAGs() now return objects of a
fitted_DAG, that has it's separate
plot method. The
method for objects of class
DAG has been simplified.
Model averaging now returns standard errors and confidence intervals based on
MuMIn package (issue #1).
A new function
plot_coefs for plotting regression coefficients and their
confidence intervals has been added.