From c62e1163290686a0a40318bd3b444c37538e5774 Mon Sep 17 00:00:00 2001 From: "Martin R. Smith" Date: Thu, 22 Oct 2020 08:08:44 +0100 Subject: [PATCH] v1.2.0 (#55) --- .Rbuildignore | 2 +- .zenodo.json | 2 +- DESCRIPTION | 6 ++---- NEWS.md | 46 +++++++++++++++------------------------- R/Metrics.R | 8 +++---- R/Quartet-package.R | 2 +- R/VisualizeQuartets.R | 6 +++--- R/zzz.R | 1 - README.md | 4 ++-- codemeta.json | 8 +++---- cran-comments.md | 8 +++---- inst/WORDLIST | 8 +++++++ man/Quartet-package.Rd | 6 +++--- man/SimilarityMetrics.Rd | 8 +++---- man/VisualizeQuartets.Rd | 9 ++++---- 15 files changed, 59 insertions(+), 65 deletions(-) diff --git a/.Rbuildignore b/.Rbuildignore index 1231fcec..540ea08d 100644 --- a/.Rbuildignore +++ b/.Rbuildignore @@ -22,4 +22,4 @@ revdep ^CODE_OF_CONDUCT\.md$ ^CONTRIBUTING\.md$ ^codemeta\.json$ -CRAN-RELEASE +^CRAN-RELEASE$ diff --git a/.zenodo.json b/.zenodo.json index cfee1234..52926608 100644 --- a/.zenodo.json +++ b/.zenodo.json @@ -2,7 +2,7 @@ "description": "An R package that calculates distances between phylogenetic topologies, integrating the tqDist algorithm for quartet distances", "license": "gpl-3.0", "title": "Quartet: Comparison of Phylogenetic Trees Using Quartet and Bipartition Measures", - "version": "v1.1.0", + "version": "v1.2.0", "upload_type": "software", "creators": [ { diff --git a/DESCRIPTION b/DESCRIPTION index 4ff65c36..37b0f178 100644 --- a/DESCRIPTION +++ b/DESCRIPTION @@ -1,5 +1,5 @@ Package: Quartet -Version: 1.1.0.9007 +Version: 1.2.0 Title: Comparison of Phylogenetic Trees Using Quartet and Split Measures Description: Calculates the number of four-taxon subtrees consistent with a pair of cladograms, calculating the symmetric quartet distance of Bandelt & Dress (1986), @@ -34,7 +34,7 @@ Imports: ape, Rdpack, Ternary (>= 1.0), - TreeTools (>= 1.3.1.9000), + TreeTools (>= 1.4.0), viridisLite Suggests: bookdown, @@ -45,8 +45,6 @@ Suggests: testthat, usethis, vdiffr -Remotes: - ms609/TreeTools SystemRequirements: C++11 RdMacros: Rdpack LinkingTo: Rcpp diff --git a/NEWS.md b/NEWS.md index cd2711c9..fe81c63e 100644 --- a/NEWS.md +++ b/NEWS.md @@ -1,42 +1,30 @@ -# Quartet v1.1.0.9007 (development) +# Quartet v1.2.0 +## New features + - `CompareQuartetsMulti()` compares quartet status in one tree with status in + multiple others. + - `VisualizeQuartets()` depicts contribution of splits to quartet score. + - `SimilarityToReference()` allows comparison against specified reference + topology. + +## Changes + - Deprecate `RobinsonFoulds()`: renamed to `RawSymmetricDifference()`. - `QuartetState[s]()` now uses sister-of-4 notation, rather than sister-of-1, to give values within [0, 3]. - - Small improvements to `PlotQuartet()`. - - Deprecate `RobinsonFoulds()`: renamed to `RawSymmetricDifference()`. - - New function `VisualizeQuartets()` shows contribution of splits to quartet - score. - -# Quartet v1.1.0.9006 (development) - - `ManyToManyQuartetAgreement()` now returns entries for `N` and `Q`. - -# Quartet v1.1.0.9005 (development) - - - Support for non-identical leaf samples in `QuartetStatus()`. - -# Quartet v1.1.0.9004 (development) - - - Remove errant name when comparing unnamed tree pairs. - - New function `SimilarityToReference()` to compare against reference topology. - -# Quartet v1.1.0.9003 (development) - - C++ implementation of `AllQuartets()` and `QuartetStates()`. - -# Quartet v1.1.0.9002 (development) - +## Improvements + - Faster C++ implementation of `AllQuartets()` and `QuartetStates()`. + - `QuartetStatus()` now supports non-identical leaf samples. + - `SimilarityMetrics()` now handles single tree comparisons. - Correctly calculate resolution of unrooted trees with unconventional node numbering conventions. + - Remove errant name when comparing unnamed tree pairs. + - Small improvements to `PlotQuartet()`. - Minor efficiency improvements. - -# Quartet v1.1.0.9001 (development) - - - New function `CompareQuartetsMulti()` compares quartet status in one tree - with status in multiple others. - - `SimilarityMetrics()` now handles single tree comparisons. - Documentation improvements. + # Quartet v1.1.0 - Pass trees directly to C, without writing to temporary intermediate file. diff --git a/R/Metrics.R b/R/Metrics.R index 98f8065e..b7f32043 100644 --- a/R/Metrics.R +++ b/R/Metrics.R @@ -49,7 +49,7 @@ #' most relationships but are poorly resolved. #' As such, it is essential to contextualize the symmetric difference by #' appropriate normalization (Smith 2019). -#' Mutliple approaches to normalization have been proposed: +#' Multiple approaches to normalization have been proposed: #' #' The total number of resolved quartets or partitions present in both trees #' (Day 1986): @@ -72,12 +72,12 @@ #' quartet's resolution in the reconstructed tree is 'correct', given by #' (Asher & Smith forthcoming): #' -#' * SimilarityToReference (STR): (_s_ + (_r1_ + _r2_ + _u_) / 3) / _Q_ +#' * Similarity to Reference (S2R): (_s_ + (_r1_ + _r2_ + _u_) / 3) / _Q_ #' #' This may optionally be normalized with reference to the maximum possible #' similarity, (_s_ + _d_ + _r2_ + (_r1_ + _u_) / 3) / _Q_, subtracting -#' 1/3 (the probability of matching at random) from both the STR score and -#' maxmium possible score before dividing; then, a tree scores zero if it +#' 1/3 (the probability of matching at random) from both the S2R score and +#' maximum possible score before dividing; then, a tree scores zero if it #' is as different from the true tree as a random or fully unresolved tree, #' and one if it is as 'true' as can be known. #' diff --git a/R/Quartet-package.R b/R/Quartet-package.R index 3e2b8c80..5339eb39 100644 --- a/R/Quartet-package.R +++ b/R/Quartet-package.R @@ -57,7 +57,7 @@ #' for comparing phylogenetic trees. Bioinformatics, in production. #' https://dx.doi.org/10.1093/bioinformatics/btaa614/5866976 #' -#' - Smith, M.R. 2021. The importance of methodology when analyzing landscapes of +#' - Smith, M.R. 2021. The importance of methodology when analysing landscapes of #' phylogenetic trees. Forthcoming. #' #' - Steel, M. and Penny, D. 1993. Distributions of tree comparison metrics: diff --git a/R/VisualizeQuartets.R b/R/VisualizeQuartets.R index 99a29cef..77707bc4 100644 --- a/R/VisualizeQuartets.R +++ b/R/VisualizeQuartets.R @@ -4,14 +4,14 @@ #' @param setPar Logical specifying whether graphical parameters should be set #' to display trees side by side. #' @param style Character string specifying split labels with an unambiguous -#' abbrevation of: +#' abbreviation of: #' - `label`: Label stating proportion of resolved quartets in agreement, #' coloured accordingly; #' - `pie`: Pie chart showing proportion of quartets in agreement, sized #' according to number of quartets influenced by each split; -#' - `bar`: Bar showing propotion of quartets in agreement, labelled; +#' - `bar`: Bar showing proportion of quartets in agreement, labelled; #' - `size`: Circle coloured according to proportion of quartets in agreement, -#' with area corrsponding to number of quartet statements associated with +#' with area corresponding to number of quartet statements associated with #' split. #' @param precision Integer specifying number of significant figures to display #' when reporting matching scores. diff --git a/R/zzz.R b/R/zzz.R index 84fbfc23..fad8f497 100644 --- a/R/zzz.R +++ b/R/zzz.R @@ -11,7 +11,6 @@ release_questions <- function() { # # codemetar::write_codemeta() # check_win_devel(); rhub::check_for_cran() -# list_my_checks() # list_package_checks # revdepcheck::revdep_check() # build_vignettes() # tools::resaveRdaFiles('data', compress='auto') - is default of bzip2 the optimal? diff --git a/README.md b/README.md index ef88f50b..a9bb7ec3 100644 --- a/README.md +++ b/README.md @@ -78,7 +78,7 @@ useful to you. for comparing phylogenetic trees. Bioinformatics, in production. https://dx.doi.org/10.1093/bioinformatics/btaa614/5866976 -- Smith, M.R. 2021. The importance of methodology when analyzing landscapes of +- Smith, M.R. 2021. The importance of methodology when analysing landscapes of phylogenetic trees. Forthcoming. - Steel, M. and Penny, D. 1993. Distributions of tree comparison metrics: @@ -86,5 +86,5 @@ useful to you. https://doi.org/10.1093/sysbio/42.2.126 Please note that the 'Quartet' project is released with a -[Contributor Code of Conduct](CODE_OF_CONDUCT.md). +[Contributor Code of Conduct](https://ms609.github.io/Quartet/CODE_OF_CONDUCT.html). By contributing to this project, you agree to abide by its terms. diff --git a/codemeta.json b/codemeta.json index 2b1b52b5..e514cf84 100644 --- a/codemeta.json +++ b/codemeta.json @@ -10,7 +10,7 @@ "codeRepository": "https://github.com/ms609/Quartet/", "issueTracker": "https://github.com/ms609/Quartet/issues/", "license": "https://spdx.org/licenses/GPL-2.0", - "version": "1.1.0.9007", + "version": "1.2.0", "programmingLanguage": { "@type": "ComputerLanguage", "name": "R", @@ -198,14 +198,14 @@ "@type": "SoftwareApplication", "identifier": "TreeTools", "name": "TreeTools", - "version": ">= 1.3.1.9000", + "version": ">= 1.4.0", "provider": { "@id": "https://cran.r-project.org", "@type": "Organization", "name": "Comprehensive R Archive Network (CRAN)", "url": "https://cran.r-project.org" }, - "sameAs": "https://github.com/ms609/TreeTools" + "sameAs": "https://CRAN.R-project.org/package=TreeTools" }, { "@type": "SoftwareApplication", @@ -339,5 +339,5 @@ "https://ms609.github.io/Quartet", "https://ms609.github.io/Quartet/" ], - "fileSize": "1231.012KB" + "fileSize": "1343.465KB" } diff --git a/cran-comments.md b/cran-comments.md index 72908638..5eff44bd 100644 --- a/cran-comments.md +++ b/cran-comments.md @@ -1,6 +1,6 @@ ## Test environments -* local Windows 10 install, R 3.6.1 -* Ubuntu 16.04.6 LTS, R 3.4.2, release and devel, via [Travis CI](https://travis-ci.org/ms609/Quartet) +* local Windows 10 install, R 4.0.2 +* Ubuntu 16.04.6 LTS, R 3.4.0, release and devel, via [Travis CI](https://travis-ci.org/ms609/Quartet/) * Mac OS X 10.13.6, R release, via Travis * win-builder, with `check_win_devel()` * R-hub, with `check_rhub(platforms = rhub::platforms()[[1]])` @@ -29,5 +29,5 @@ These URLs are generated from DOIs in citations, and are valid. ## Downstream dependencies -The modifications do not impact the reverse dependency `CongreveLamsdell2016` -(which I maintain). +The modifications do not impact the reverse dependencies `CongreveLamsdell2016` +or `TreeDist` (which I maintain). diff --git a/inst/WORDLIST b/inst/WORDLIST index 4f879725..b4da8702 100644 --- a/inst/WORDLIST +++ b/inst/WORDLIST @@ -12,6 +12,7 @@ Meacham ORCID R's Rtools +S2R SJA SPR SSJA @@ -21,16 +22,23 @@ SlowQuartet Steinhaus Stølting Syst +TreeDist +TreeDistData +TreeTools Zool ac binom +btaa btu codecov dQ doi durham +dx etc frac +io +github memoization org partitionwise diff --git a/man/Quartet-package.Rd b/man/Quartet-package.Rd index bd27cb3d..4edb7598 100644 --- a/man/Quartet-package.Rd +++ b/man/Quartet-package.Rd @@ -39,8 +39,8 @@ The underlying 'tqDist' library may handle trees with up to 568 leaves, and 64-bit integer representations could increase this number further. Making either of these improvements within the R package would require substantial additional work, but could be implemented -- do -\href{https://ms609.github.io/Quartet/issues}{file an issue} if this would be -useful to you. +\href{https://github.com/ms609/Quartet/issues/new/}{file an issue} if this would +be useful to you. } } \references{ @@ -61,7 +61,7 @@ informative trees from simulated morphological datasets. Biol. Lett. \item Smith, M.R. 2020. Information theoretic generalized Robinson–Foulds metrics for comparing phylogenetic trees. Bioinformatics, in production. https://dx.doi.org/10.1093/bioinformatics/btaa614/5866976 -\item Smith, M.R. 2021. The importance of methodology when analyzing landscapes of +\item Smith, M.R. 2021. The importance of methodology when analysing landscapes of phylogenetic trees. Forthcoming. \item Steel, M. and Penny, D. 1993. Distributions of tree comparison metrics: some new results. Syst. Biol. 42: 126-141. diff --git a/man/SimilarityMetrics.Rd b/man/SimilarityMetrics.Rd index 5060baf8..33a5be15 100644 --- a/man/SimilarityMetrics.Rd +++ b/man/SimilarityMetrics.Rd @@ -114,7 +114,7 @@ well-resolved but disagree on many relationships; or if they agree on most relationships but are poorly resolved. As such, it is essential to contextualize the symmetric difference by appropriate normalization (Smith 2019). -Mutliple approaches to normalization have been proposed: +Multiple approaches to normalization have been proposed: The total number of resolved quartets or partitions present in both trees (Day 1986): @@ -140,13 +140,13 @@ In such settings, the desired score is the expectation that a given quartet's resolution in the reconstructed tree is 'correct', given by (Asher & Smith forthcoming): \itemize{ -\item SimilarityToReference (STR): (\emph{s} + (\emph{r1} + \emph{r2} + \emph{u}) / 3) / \emph{Q} +\item Similarity to Reference (S2R): (\emph{s} + (\emph{r1} + \emph{r2} + \emph{u}) / 3) / \emph{Q} } This may optionally be normalized with reference to the maximum possible similarity, (\emph{s} + \emph{d} + \emph{r2} + (\emph{r1} + \emph{u}) / 3) / \emph{Q}, subtracting -1/3 (the probability of matching at random) from both the STR score and -maxmium possible score before dividing; then, a tree scores zero if it +1/3 (the probability of matching at random) from both the S2R score and +maximum possible score before dividing; then, a tree scores zero if it is as different from the true tree as a random or fully unresolved tree, and one if it is as 'true' as can be known. } diff --git a/man/VisualizeQuartets.Rd b/man/VisualizeQuartets.Rd index 28f8a129..ef7688c4 100644 --- a/man/VisualizeQuartets.Rd +++ b/man/VisualizeQuartets.Rd @@ -21,14 +21,15 @@ VisualizeQuartets( \item{tree1, tree2}{Trees of class \code{phylo}, with identical leaf labels.} \item{style}{Character string specifying split labels with an unambiguous -abbrevation of: +abbreviation of: \itemize{ \item \code{label}: Label stating proportion of resolved quartets in agreement, coloured accordingly; -\item \code{pie}: Pie chart showing proportion of quartets in agreement; -\item \code{bar}: Bar showing propotion of quartets in agreement, labelled; +\item \code{pie}: Pie chart showing proportion of quartets in agreement, sized +according to number of quartets influenced by each split; +\item \code{bar}: Bar showing proportion of quartets in agreement, labelled; \item \code{size}: Circle coloured according to proportion of quartets in agreement, -with area corrsponding to number of quartet statements associated with +with area corresponding to number of quartet statements associated with split. }}