diff --git a/.Rbuildignore b/.Rbuildignore index 3435b74..1e810ab 100644 --- a/.Rbuildignore +++ b/.Rbuildignore @@ -1,5 +1,11 @@ -revdep examples +repo +revdep +scripts +tools +wiki +www +yaml tests/Makefile tests/(.+?)\.png$ tests/(.+?)\.pdf$ @@ -8,8 +14,9 @@ inst/doc/Makefile inst/doc/(.+?).md inst/doc/(.+?).Rmd man/roxygen +Doxyfile LICENSE\.md$ -README\.md$ +README\.(.?)$ CRAN\.md$ TODO\.md$ ^\.gitignore$ @@ -32,16 +39,13 @@ TODO\.md$ \.tests Makefile rules.mk -scripts lib -tools +libs library check -www ^(.+?)\.pdf ^(.+?)\.tar\.gz ^(.+?)\.tgz ^(.+?)\.zip -data/primates.csv covr.html covr.rds diff --git a/.github/workflows/binary-build.yml b/.github/workflows/binary-build.yml index ebb5c2c..38ba430 100644 --- a/.github/workflows/binary-build.yml +++ b/.github/workflows/binary-build.yml @@ -19,7 +19,7 @@ jobs: fail-fast: false steps: - - uses: actions/checkout@v3.1.0 + - uses: actions/checkout@v4 - uses: r-lib/actions/setup-r@v2 with: @@ -36,7 +36,7 @@ jobs: mkdir -p ${{ github.workspace }}/artifacts cp ${{ env.release_name }}.tar.gz ${{ github.workspace }}/artifacts - - uses: actions/upload-artifact@v3.1.1 + - uses: actions/upload-artifact@v4 with: name: Source tarball path: ${{ github.workspace }}/artifacts/${{ env.release_name }}.tar.gz @@ -54,7 +54,7 @@ jobs: - {os: windows-latest, r: 'release', ext: "zip"} steps: - - uses: actions/checkout@v3.1.0 + - uses: actions/checkout@v4 - uses: r-lib/actions/setup-r@v2 with: @@ -74,7 +74,7 @@ jobs: mkdir -p ${{ github.workspace }}/artifacts cp ../${{ env.release_name }}.${{ matrix.config.ext }} ${{ github.workspace }}/artifacts - - uses: actions/upload-artifact@v3.1.1 + - uses: actions/upload-artifact@v4 with: name: ${{ matrix.config.os }}-${{ matrix.config.r }} path: ${{ github.workspace }}/artifacts/${{ env.release_name }}.${{ matrix.config.ext }} diff --git a/.github/workflows/r-cmd-check.yml b/.github/workflows/r-cmd-check.yml index 2b45fc2..e9334bd 100644 --- a/.github/workflows/r-cmd-check.yml +++ b/.github/workflows/r-cmd-check.yml @@ -31,31 +31,9 @@ jobs: env: GITHUB_PAT: ${{ secrets.GITHUB_TOKEN }} R_KEEP_PKG_SOURCE: yes - _R_CHECK_DEPENDS_ONLY_: false - _R_CHECK_ALL_NON_ISO_C_: true - _R_CHECK_CODE_ASSIGN_TO_GLOBALENV_: true - _R_CHECK_CODE_ATTACH_: true - _R_CHECK_CODE_DATA_INTO_GLOBALENV_: true - _R_CHECK_CODE_USAGE_VIA_NAMESPACES_: true - _R_CHECK_DEPRECATED_DEFUNCT_: true - _R_CHECK_EXECUTABLES_EXCLUSIONS_: false - _R_CHECK_INSTALL_DEPENDS_: true - _R_CHECK_NO_RECOMMENDED_: true - _R_CHECK_OVERWRITE_REGISTERED_S3_METHODS_: true - _R_CHECK_REPLACING_IMPORTS_: true - _R_CHECK_S3_METHODS_NOT_REGISTERED_: true - _R_CHECK_SCREEN_DEVICE_: stop - _R_CHECK_SRC_MINUS_W_IMPLICIT_: true - _R_CHECK_SRC_MINUS_W_UNUSED_: true - _R_CHECK_SUGGESTS_ONLY_: true - _R_CHECK_TOPLEVEL_FILES_: true - _R_CHECK_VC_DIRS_: true - _R_CHECK_WALL_FORTRAN_: true - _R_CHECK_USE_CODETOOLS_: true - _R_CHECK_CODETOOLS_PROFILE_: "suppressLocalUnused=FALSE,suppressPartialMatchArgs=FALSE,suppressParamUnused=TRUE,suppressUndefined=FALSE" steps: - - uses: actions/checkout@v3.1.0 + - uses: actions/checkout@v4 - uses: r-lib/actions/setup-r@v2 with: @@ -69,7 +47,7 @@ jobs: - uses: r-lib/actions/check-r-package@v2 - - uses: actions/upload-artifact@v3.1.1 + - uses: actions/upload-artifact@v4 with: name: ${{ matrix.config.os }}-${{ matrix.config.r }}-results - path: check + path: check/${{ vars.repo_name }}.Rcheck diff --git a/.github/workflows/test-coverage.yml b/.github/workflows/test-coverage.yml index 3769c24..ab8d287 100644 --- a/.github/workflows/test-coverage.yml +++ b/.github/workflows/test-coverage.yml @@ -18,7 +18,7 @@ jobs: GITHUB_PAT: ${{ secrets.GITHUB_TOKEN }} steps: - - uses: actions/checkout@v3.1.0 + - uses: actions/checkout@v4 - uses: r-lib/actions/setup-r@v2 with: diff --git a/.gitignore b/.gitignore index 2be66db..4015062 100644 --- a/.gitignore +++ b/.gitignore @@ -22,6 +22,8 @@ lib library check +repo +wiki www tmp covr.html diff --git a/DESCRIPTION b/DESCRIPTION index 9878875..28706fa 100644 --- a/DESCRIPTION +++ b/DESCRIPTION @@ -1,8 +1,8 @@ Package: ouch Type: Package Title: Ornstein-Uhlenbeck Models for Phylogenetic Comparative Hypotheses -Version: 2.19-0 -Date: 2023-04-24 +Version: 2.19-1 +Date: 2024-02-14 Authors@R: c(person(given=c("Aaron","A."),family="King",role=c("aut","cre"),email="kingaa@umich.edu",comment=c(ORCID="0000-0001-6159-3207")), person(given=c("Marguerite","A."),family="Butler",role=c("ctb"))) Maintainer: Aaron A. King @@ -15,7 +15,7 @@ License: GPL-3 LazyLoad: true LazyData: true Roxygen: list(roclets = c("collate", "namespace", "rd"), markdown = TRUE) -RoxygenNote: 7.2.3 +RoxygenNote: 7.3.1 BugReports: https://github.com/kingaa/ouch/issues/ Encoding: UTF-8 Collate: diff --git a/Makefile b/Makefile index e09be30..e5aca84 100644 --- a/Makefile +++ b/Makefile @@ -1,4 +1,4 @@ -REPODIR = ../www +REPODIR = repo INCLUDES= HEADERS= diff --git a/R/package.R b/R/package.R index 1fa60e4..cf5f249 100644 --- a/R/package.R +++ b/R/package.R @@ -4,9 +4,8 @@ #' Multivariate data and complex adaptive hypotheses are supported. #' #' @name ouch-package -#' @aliases ouch +#' @aliases ouch,package ouch-package #' @rdname package -#' @docType package #' @family phylogenetic comparative models #' @family methods for ouch trees #' @family examples @@ -40,7 +39,7 @@ #' @useDynLib ouch, .registration = TRUE #' @import methods #' @keywords models -NULL +"_PACKAGE" pStop <- function (fn, ...) { fn <- as.character(fn) diff --git a/data/primates.csv b/data/primates.csv deleted file mode 100644 index 073cafb..0000000 --- a/data/primates.csv +++ /dev/null @@ -1,24 +0,0 @@ -nodes;ancestors;times;labels -1;NA;0;NA -2;1;0.267;NA -3;4;0.977;NA -4;5;0.929;NA -5;10;0.879;NA -6;7;0.93;NA -7;8;0.901;NA -8;9;0.755;NA -9;10;0.686;NA -10;11;0.439;NA -11;1;0.231;NA -12;2;1;Tarsius syrichta -13;11;1;Saimiri sciureus -14;8;1;Pongo -15;6;1;Pan -16;3;1;Macaca fuscata -17;5;1;Macaca sylvanus -18;3;1;Macaca mulatta -19;4;1;Macaca fascicularis -20;2;1;Lemur catta -21;9;1;Hylobates -22;6;1;Homo sapiens -23;7;1;Gorilla diff --git a/man/package.Rd b/man/package.Rd index 6e83ff8..60a48b4 100644 --- a/man/package.Rd +++ b/man/package.Rd @@ -2,8 +2,9 @@ % Please edit documentation in R/package.R \docType{package} \name{ouch-package} -\alias{ouch-package} \alias{ouch} +\alias{ouch-package} +\alias{ouch,package} \title{Ornstein-Uhlenbeck methods for comparative phylogenetic hypotheses} \description{ The \pkg{ouch} package provides facilities for phylogenetic comparative analysis based on Ornstein-Uhlenbeck models of trait evolution along a phylogeny. @@ -45,6 +46,13 @@ Execute \code{citation("ouch")} to view the correct citation for publications. \Cressler2015 } \seealso{ +Useful links: +\itemize{ + \item \url{https://kingaa.github.io/ouch/} + \item Report bugs at \url{https://github.com/kingaa/ouch/issues/} +} + + Other phylogenetic comparative models: \code{\link{brown}()}, \code{\link{hansen}()}, diff --git a/tests/ape2ouch.Rout b/tests/ape2ouch.Rout index f440377..f831c0a 100644 --- a/tests/ape2ouch.Rout +++ b/tests/ape2ouch.Rout @@ -1,5 +1,5 @@ -R version 4.3.0 (2023-04-21) -- "Already Tomorrow" +R version 4.3.2 (2023-10-31) -- "Eye Holes" Copyright (C) 2023 The R Foundation for Statistical Computing Platform: x86_64-pc-linux-gnu (64-bit) diff --git a/tests/bapst.Rout.save b/tests/bapst.Rout.save index da1b107..31abc14 100644 --- a/tests/bapst.Rout.save +++ b/tests/bapst.Rout.save @@ -1,5 +1,5 @@ -R version 4.3.0 (2023-04-21) -- "Already Tomorrow" +R version 4.3.2 (2023-10-31) -- "Eye Holes" Copyright (C) 2023 The R Foundation for Statistical Computing Platform: x86_64-pc-linux-gnu (64-bit) @@ -23,6 +23,6 @@ Type 'q()' to quit R. > tr <- with(x,ouchtree(nodes=node,ancestors=ancestor,times=time,labels=species)) > toc <- Sys.time() > print(toc-tic) -Time difference of 0.005033731 secs +Time difference of 0.005596876 secs > plot(tr) > diff --git a/tests/bergmann.Rout.save b/tests/bergmann.Rout.save index 6621068..0052045 100644 --- a/tests/bergmann.Rout.save +++ b/tests/bergmann.Rout.save @@ -1,5 +1,5 @@ -R version 4.3.0 (2023-04-21) -- "Already Tomorrow" +R version 4.3.2 (2023-10-31) -- "Eye Holes" Copyright (C) 2023 The R Foundation for Statistical Computing Platform: x86_64-pc-linux-gnu (64-bit) diff --git a/tests/boot.Rout.save b/tests/boot.Rout.save index 7c686fc..25f2670 100644 --- a/tests/boot.Rout.save +++ b/tests/boot.Rout.save @@ -1,5 +1,5 @@ -R version 4.3.0 (2023-04-21) -- "Already Tomorrow" +R version 4.3.2 (2023-10-31) -- "Eye Holes" Copyright (C) 2023 The R Foundation for Statistical Computing Platform: x86_64-pc-linux-gnu (64-bit) @@ -52,7 +52,7 @@ btstrp> b5 <- sapply(simdat,function(x)summary(update(h5,data=x))$aic.c) btstrp> toc <- Sys.time() btstrp> print(toc-tic) -Time difference of 12.61242 secs +Time difference of 13.27121 secs btstrp> cat("approximate 95% AIC.c cutoff",signif(quantile(b1-b5,0.95),digits=3),"\n") approximate 95% AIC.c cutoff 2.58 diff --git a/tests/brown.Rout.save b/tests/brown.Rout.save index ef79274..5b49c2f 100644 --- a/tests/brown.Rout.save +++ b/tests/brown.Rout.save @@ -1,5 +1,5 @@ -R version 4.3.0 (2023-04-21) -- "Already Tomorrow" +R version 4.3.2 (2023-10-31) -- "Eye Holes" Copyright (C) 2023 The R Foundation for Statistical Computing Platform: x86_64-pc-linux-gnu (64-bit) diff --git a/tests/exacttree.Rout.save b/tests/exacttree.Rout.save index e349aff..a97671d 100644 --- a/tests/exacttree.Rout.save +++ b/tests/exacttree.Rout.save @@ -1,5 +1,5 @@ -R version 4.3.0 (2023-04-21) -- "Already Tomorrow" +R version 4.3.2 (2023-10-31) -- "Eye Holes" Copyright (C) 2023 The R Foundation for Statistical Computing Platform: x86_64-pc-linux-gnu (64-bit) diff --git a/tests/glssoln.Rout.save b/tests/glssoln.Rout.save index 8f9b16e..8506c6e 100644 --- a/tests/glssoln.Rout.save +++ b/tests/glssoln.Rout.save @@ -1,5 +1,5 @@ -R version 4.3.0 (2023-04-21) -- "Already Tomorrow" +R version 4.3.2 (2023-10-31) -- "Eye Holes" Copyright (C) 2023 The R Foundation for Statistical Computing Platform: x86_64-pc-linux-gnu (64-bit) @@ -27,7 +27,7 @@ $residuals [1] NA Warning message: -in 'ouch:::glssoln': Choleski decomposition of variance-covariance matrix fails with error: "the leading minor of order 1 is not positive definite". +in 'ouch:::glssoln': Choleski decomposition of variance-covariance matrix fails with error: "the leading minor of order 1 is not positive". > try(ouch:::glssoln(matrix(c(1,1,0,1),2,2),c(1,1),matrix(c(1,1,1,1),2,2))) $coeff [1] NA NA @@ -36,7 +36,7 @@ $residuals [1] NA NA Warning message: -in 'ouch:::glssoln': Choleski decomposition of variance-covariance matrix fails with error: "the leading minor of order 2 is not positive definite". +in 'ouch:::glssoln': Choleski decomposition of variance-covariance matrix fails with error: "the leading minor of order 2 is not positive". > ouch:::glssoln(matrix(c(1,1,0,1),2,2),c(1,1),matrix(c(2,1,1,2),2,2)) -> x > stopifnot( + coeff=all.equal(as.numeric(x$coeff),c(1,0)), diff --git a/tests/hansen.Rout.save b/tests/hansen.Rout.save index 2f5ac1c..1c33479 100644 --- a/tests/hansen.Rout.save +++ b/tests/hansen.Rout.save @@ -1,5 +1,5 @@ -R version 4.3.0 (2023-04-21) -- "Already Tomorrow" +R version 4.3.2 (2023-10-31) -- "Eye Holes" Copyright (C) 2023 The R Foundation for Statistical Computing Platform: x86_64-pc-linux-gnu (64-bit) diff --git a/tests/ouchtree.Rout.save b/tests/ouchtree.Rout.save index 213e4c7..0535a18 100644 --- a/tests/ouchtree.Rout.save +++ b/tests/ouchtree.Rout.save @@ -1,5 +1,5 @@ -R version 4.3.0 (2023-04-21) -- "Already Tomorrow" +R version 4.3.2 (2023-10-31) -- "Eye Holes" Copyright (C) 2023 The R Foundation for Statistical Computing Platform: x86_64-pc-linux-gnu (64-bit) diff --git a/tests/paint.Rout.save b/tests/paint.Rout.save index 5814e45..8610a51 100644 --- a/tests/paint.Rout.save +++ b/tests/paint.Rout.save @@ -1,5 +1,5 @@ -R version 4.3.0 (2023-04-21) -- "Already Tomorrow" +R version 4.3.2 (2023-10-31) -- "Eye Holes" Copyright (C) 2023 The R Foundation for Statistical Computing Platform: x86_64-pc-linux-gnu (64-bit) diff --git a/tests/plot.Rout.save b/tests/plot.Rout.save index f8d1c83..21647f9 100644 --- a/tests/plot.Rout.save +++ b/tests/plot.Rout.save @@ -1,5 +1,5 @@ -R version 4.3.0 (2023-04-21) -- "Already Tomorrow" +R version 4.3.2 (2023-10-31) -- "Eye Holes" Copyright (C) 2023 The R Foundation for Statistical Computing Platform: x86_64-pc-linux-gnu (64-bit) diff --git a/tests/simtree.Rout.save b/tests/simtree.Rout.save index 4e2e55c..7e67a6f 100644 --- a/tests/simtree.Rout.save +++ b/tests/simtree.Rout.save @@ -1,5 +1,5 @@ -R version 4.3.0 (2023-04-21) -- "Already Tomorrow" +R version 4.3.2 (2023-10-31) -- "Eye Holes" Copyright (C) 2023 The R Foundation for Statistical Computing Platform: x86_64-pc-linux-gnu (64-bit) @@ -92,7 +92,7 @@ Type 'q()' to quit R. > tree <- with(x,ouchtree(node,ancestor,time)) > toc <- Sys.time() > print(toc-tic) -Time difference of 3.478733 secs +Time difference of 2.687218 secs > > bfit <- brown(data=x[c("A","B")],tree) > print(summary(bfit)) @@ -135,7 +135,7 @@ $dof > hfit <- hansen(data=x[c("A","B")],tree=tree,regimes=x['reg'],sqrt.alpha=a,sigma=s,fit=F) > toc <- Sys.time() > print(toc-tic) -Time difference of 5.732939 secs +Time difference of 6.222583 secs > print(summary(hfit)) $call hansen(data = x[c("A", "B")], tree = tree, regimes = x["reg"], @@ -203,7 +203,7 @@ $dof > tree <- with(x,ouchtree(node,ancestor,time)) > toc <- Sys.time() > print(toc-tic) -Time difference of 1.490282 secs +Time difference of 1.404474 secs > > bfit <- brown(data=x[c("A","B")],tree) > print(summary(bfit)) @@ -283,7 +283,7 @@ $dof > hfit <- hansen(data=x[c("A","B")],tree=tree,regimes=x['reg'],sqrt.alpha=a,sigma=s,fit=F) > toc <- Sys.time() > print(toc-tic) -Time difference of 3.648121 secs +Time difference of 3.714571 secs > print(summary(hfit)) $call hansen(data = x[c("A", "B")], tree = tree, regimes = x["reg"], diff --git a/tests/snizard.Rout.save b/tests/snizard.Rout.save index 260c346..cc3d070 100644 --- a/tests/snizard.Rout.save +++ b/tests/snizard.Rout.save @@ -1,5 +1,5 @@ -R version 4.3.0 (2023-04-21) -- "Already Tomorrow" +R version 4.3.2 (2023-10-31) -- "Eye Holes" Copyright (C) 2023 The R Foundation for Statistical Computing Platform: x86_64-pc-linux-gnu (64-bit) @@ -58,8 +58,8 @@ Type 'q()' to quit R. + + } Loading required package: ape -Time difference of 0.3740759 secs -Time difference of 5.521165 secs +Time difference of 0.2880907 secs +Time difference of 5.005338 secs $BM.1 sigma theta.log.SVL.SE sigma.sq.matrix 1.306906 2.528162 1.708003 437.546555 diff --git a/tools/check.env b/tools/check.env index cb90f99..a200412 100644 --- a/tools/check.env +++ b/tools/check.env @@ -1,3 +1,4 @@ +_R_CHECK_AS_DATA_FRAME_EXPLICIT_METHOD_=true _R_CHECK_ALL_NON_ISO_C_=false _R_CHECK_ALWAYS_LOG_VIGNETTE_OUTPUT_=false _R_CHECK_ASCII_CODE_=true