* using log directory 'd:/RCompile/CRANincoming/R-devel/TAD.Rcheck' * using R Under development (unstable) (2024-10-09 r87215 ucrt) * using platform: x86_64-w64-mingw32 * R was compiled by gcc.exe (GCC) 13.2.0 GNU Fortran (GCC) 13.2.0 * running under: Windows Server 2022 x64 (build 20348) * using session charset: UTF-8 * checking for file 'TAD/DESCRIPTION' ... OK * this is package 'TAD' version '1.0.0' * package encoding: UTF-8 * checking CRAN incoming feasibility ... NOTE Maintainer: 'Raphael Martin ' New submission License components with restrictions and base license permitting such: BSD_3_clause + file LICENSE File 'LICENSE': # BSD 3-Clause License Copyright (c) 2022, Institut National de Recherche pour l'Agriculture, l'Alimentation et l'Environnement (INRAE)/Unité mixte de Recherche sur l'Ecosystème Prairial (UREP) All rights reserved. Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met: 1. Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer. 2. Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution. 3. Neither the name of the copyright holder nor the names of its contributors may be used to endorse or promote products derived from this software without specific prior written permission. THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. Package has a VignetteBuilder field but no prebuilt vignette index. * checking package namespace information ... OK * checking package dependencies ... OK * checking if this is a source package ... OK * checking if there is a namespace ... OK * checking for hidden files and directories ... OK * checking for portable file names ... OK * checking whether package 'TAD' can be installed ... OK * checking installed package size ... OK * checking package directory ... OK * checking for future file timestamps ... OK * checking DESCRIPTION meta-information ... NOTE License stub is invalid DCF. * checking top-level files ... OK * checking for left-over files ... OK * checking index information ... OK * checking package subdirectories ... OK * checking code files for non-ASCII characters ... OK * checking R files for syntax errors ... OK * checking whether the package can be loaded ... OK * checking whether the package can be loaded with stated dependencies ... OK * checking whether the package can be unloaded cleanly ... OK * checking whether the namespace can be loaded with stated dependencies ... OK * checking whether the namespace can be unloaded cleanly ... OK * checking loading without being on the library search path ... OK * checking use of S3 registration ... OK * checking dependencies in R code ... OK * checking S3 generic/method consistency ... OK * checking replacement functions ... OK * checking foreign function calls ... OK * checking R code for possible problems ... OK * checking Rd files ... OK * checking Rd metadata ... OK * checking Rd line widths ... OK * checking Rd cross-references ... OK * checking for missing documentation entries ... OK * checking for code/documentation mismatches ... OK * checking Rd \usage sections ... OK * checking Rd contents ... OK * checking for unstated dependencies in examples ... OK * checking contents of 'data' directory ... OK * checking data for non-ASCII characters ... OK * checking LazyData ... OK * checking data for ASCII and uncompressed saves ... OK * checking installed files from 'inst/doc' ... OK * checking files in 'vignettes' ... OK * checking examples ... [30s] ERROR Running examples in 'TAD-Ex.R' failed The error most likely occurred in: > base::assign(".ptime", proc.time(), pos = "CheckExEnv") > ### Name: moments_graph > ### Title: moments_graph > ### Aliases: moments_graph > > ### ** Examples > > > results <- TAD::launch_analysis_tad( + weights = TAD::AB[, 5:102], + weights_factor = TAD::AB[, c("Year", "Plot", "Treatment", "Bloc")], + trait_data = log(TAD::trait[["SLA"]]), + aggregation_factor_name = c("Year", "Bloc"), + statistics_factor_name = (statistics_factor_name <- c("Treatment")), + randomization_number = 100 + ) Loading required package: foreach Loading required package: future > > # if you want to display the graph > graph <- TAD::moments_graph( + moments_df = results$weighted_moments, + statistics_per_observation = results$statistics_per_observation, + statistics_factor_name = statistics_factor_name, + statistics_factor_name_breaks = c("Mown_Unfertilized", "Mown_NPK"), + statistics_factor_name_col = c("#1A85FF", "#D41159") + ) > > plot(graph) > > > # if you want to save the graph as a file > # either jpg, jpeg, png or svg are > output_path <- file.path(tempdir(), "outputs") > TAD::moments_graph( + moments_df = results$weighted_moments, + statistics_per_observation = results$statistics_per_observation, + statistics_factor_name = statistics_factor_name, + statistics_factor_name_breaks = c("Mown_Unfertilized", "Mown_NPK"), + statistics_factor_name_col = c("#1A85FF", "#D41159"), + output_path = file.path(output_path, "moment_graph.png") + ) Error in `ggplot2$ggsave()`: ! Cannot find directory 'D:/temp/RtmpWW5pg9/outputs'. ℹ Please supply an existing directory or use `create.dir = TRUE`. Backtrace: ▆ 1. └─TAD::moments_graph(...) 2. └─ggplot2$ggsave(...) 3. └─ggplot2:::check_path(path, filename, create.dir) 4. └─cli::cli_abort(...) 5. └─rlang::abort(...) Execution halted * checking for unstated dependencies in 'tests' ... OK * checking tests ... ERROR Running 'testthat.R' Running the tests in 'tests/testthat.R' failed. Complete output: > # This file is part of the standard setup for testthat. > # It is recommended that you do not modify it. > # > # Where should you do additional test configuration? > # Learn more about the roles of various files in: > # * https://r-pkgs.org/tests.html > # * https://testthat.r-lib.org/reference/test_package.html#special-files > > library(testthat) > > testthat::test_check("TAD") Loading required package: TAD Starting 2 test processes [ FAIL 2 | WARN 1 | SKIP 0 | PASS 100 ] ══ Failed tests ════════════════════════════════════════════════════════════════ ── Failure ('test-tad_analysis_get_weighted_mnts.R:8:3'): Stats per random dataframes works ── `weighted_moments` (`actual`) not identical to datasets$good2$results$weighted_moments (`expected`). actual$skewness | expected$skewness [63] 0.04289098658976072 | 0.04289098658976072 [63] [64] -0.43522815475347920 | -0.43522815475347920 [64] [65] -0.59803696156483510 | -0.59803696156483510 [65] [66] -0.80161615857171009 - -0.80161615857170998 [66] [67] 0.16587424767944589 | 0.16587424767944589 [67] [68] -0.47364831234905586 | -0.47364831234905586 [68] [69] -0.68818893347382915 | -0.68818893347382915 [69] actual$skewness | expected$skewness [134] -0.70616418979290896 | -0.70616418979290896 [134] [135] 0.18167504757408809 | 0.18167504757408809 [135] [136] 0.44999655247169656 | 0.44999655247169656 [136] [137] -1.45247402477013265 - -1.45247402477013288 [137] [138] 0.41715674980749340 | 0.41715674980749340 [138] [139] 0.62031960005389686 | 0.62031960005389686 [139] [140] 0.85449604643129684 | 0.85449604643129684 [140] actual$skewness | expected$skewness [1119] -0.03181494035233438 | -0.03181494035233438 [1119] [1120] 0.00975198583644703 | 0.00975198583644703 [1120] [1121] 1.06622258682253368 | 1.06622258682253368 [1121] [1122] 0.46925734346874259 - 0.46925734346874265 [1122] [1123] -0.13163934305542177 | -0.13163934305542177 [1123] [1124] -0.02985937012713765 | -0.02985937012713765 [1124] [1125] -0.16980549320926203 | -0.16980549320926203 [1125] actual$skewness | expected$skewness [1665] -0.18411685465148075 | -0.18411685465148075 [1665] [1666] 1.45859884351357683 | 1.45859884351357683 [1666] [1667] 0.85677109806435969 | 0.85677109806435969 [1667] [1668] -0.31178183757933464 - -0.31178183757933459 [1668] [1669] 0.72893506481358439 | 0.72893506481358439 [1669] [1670] -0.56194872864097045 | -0.56194872864097045 [1670] [1671] -0.85929043222772594 | -0.85929043222772594 [1671] actual$kurtosis | expected$kurtosis [85] 3.5548386034186539 | 3.5548386034186539 [85] [86] 2.7071176279412010 | 2.7071176279412010 [86] [87] 2.7017123395381089 | 2.7017123395381089 [87] [88] 1.8861391903315843 - 1.8861391903315845 [88] [89] 2.9912762537458595 | 2.9912762537458595 [89] [90] 3.3387030075649413 | 3.3387030075649413 [90] [91] 3.1176984652152790 | 3.1176984652152790 [91] actual$kurtosis | expected$kurtosis [695] 1.4750989946865152 | 1.4750989946865152 [695] [696] 2.6968997409893185 | 2.6968997409893185 [696] [697] 3.3387835563369341 | 3.3387835563369341 [697] [698] 6.8144507911803718 - 6.8144507911803709 [698] [699] 2.5663872106716443 | 2.5663872106716443 [699] [700] 3.0713792964120499 | 3.0713792964120499 [700] [701] 3.4504242174946058 | 3.4504242174946058 [701] actual$kurtosis | expected$kurtosis [897] 1.7008701414706817 | 1.7008701414706817 [897] [898] 3.0378201875943085 | 3.0378201875943085 [898] [899] 2.6417369702351725 | 2.6417369702351725 [899] [900] 2.1513912216316649 - 2.1513912216316653 [900] [901] 3.6817644388605335 | 3.6817644388605335 [901] [902] 2.1100856117755864 | 2.1100856117755864 [902] [903] 3.7720449015574116 | 3.7720449015574116 [903] actual$distance_law | expected$distance_law [85] 1.2175048662327974 | 1.2175048662327974 [85] [86] 0.4848848171773619 | 0.4848848171773619 [86] [87] 0.8259608216169665 | 0.8259608216169665 [87] [88] -0.0292397428093636 - -0.0292397428093634 [88] [89] 0.8166659717993769 | 0.8166659717993769 [89] [90] 0.8717079603981834 | 0.8717079603981834 [90] [91] 1.1636376132625865 | 1.1636376132625865 [91] actual$distance_law | expected$distance_law [134] 1.8613328304077323 | 1.8613328304077323 [134] [135] -0.2680143410393421 | -0.2680143410393421 [135] [136] 0.1929864475989893 | 0.1929864475989893 [136] [137] 0.9672825428280625 - 0.9672825428280616 [137] [138] 1.6549433034584720 | 1.6549433034584720 [138] [139] 0.2619654157169471 | 0.2619654157169471 [139] [140] 0.5091197968012273 | 0.5091197968012273 [140] actual$distance_law | expected$distance_law [695] -0.3849122354071970 | -0.3849122354071970 [695] [696] 0.5900789721453092 | 0.5900789721453092 [696] [697] 1.3667482807940934 | 1.3667482807940934 [697] [698] 4.8425382124202700 - 4.8425382124202692 [698] [699] 0.6819399594824029 | 0.6819399594824029 [699] [700] 0.7842067037169085 | 0.7842067037169085 [700] [701] 1.5888396672551752 | 1.5888396672551752 [701] actual$distance_law | expected$distance_law [897] -0.1591677660318598 | -0.1591677660318598 [897] [898] 1.1762345030299604 | 1.1762345030299604 [898] [899] 0.2891129719599101 | 0.2891129719599101 [899] [900] 0.1232649388582532 - 0.1232649388582536 [900] [901] 1.5728120306993483 | 1.5728120306993483 [901] [902] -0.0643713261088630 | -0.0643713261088630 [902] [903] 0.9436962925956798 | 0.9436962925956798 [903] actual$distance_law | expected$distance_law [1665] 2.4467005259148493 | 2.4467005259148493 [1665] [1666] 0.9513032811842441 | 0.9513032811842441 [1666] [1667] 0.2705439236935985 | 0.2705439236935985 [1667] [1668] 0.4231705683884304 - 0.4231705683884306 [1668] [1669] 0.7163777987923652 | 0.7163777987923652 [1669] [1670] 2.5255652513213920 | 2.5255652513213920 [1670] [1671] 1.4368256115923761 | 1.4368256115923761 [1671] ── Error ('test-utilities.R:102:3'): Saving and loading abundance works ──────── Error in `file(file, ifelse(append, "a", "w"), encoding = fileEncoding)`: cannot open the connection Backtrace: ▆ 1. └─TAD:::save_abundance_dataframe(path = "/tmp/ab.csv", object = abd_df) at test-utilities.R:102:3 2. └─TAD:::save_depending_on_format(file = path, ABUNDANCE_DF_NAME) 3. └─utils::write.table(...) 4. └─base::file(file, ifelse(append, "a", "w"), encoding = fileEncoding) [ FAIL 2 | WARN 1 | SKIP 0 | PASS 100 ] Error: Test failures Execution halted * checking for unstated dependencies in vignettes ... OK * checking package vignettes ... OK * checking re-building of vignette outputs ... [191s] OK * checking PDF version of manual ... [19s] WARNING LaTeX errors when creating PDF version. This typically indicates Rd problems. LaTeX errors found: ! LaTeX Error: Something's wrong--perhaps a missing \item. See the LaTeX manual or LaTeX Companion for explanation. Type H for immediate help. ... ! LaTeX Error: Something's wrong--perhaps a missing \item. See the LaTeX manual or LaTeX Companion for explanation. Type H for immediate help. ... ! LaTeX Error: Something's wrong--perhaps a missing \item. See the LaTeX manual or LaTeX Companion for explanation. Type H for immediate help. ... ! LaTeX Error: Something's wrong--perhaps a missing \item. See the LaTeX manual or LaTeX Companion for explanation. Type H for immediate help. ... ! LaTeX Error: Something's wrong--perhaps a missing \item. See the LaTeX manual or LaTeX Companion for explanation. Type H for immediate help. ... * checking PDF version of manual without index ... ERROR * checking HTML version of manual ... OK * DONE Status: 3 ERRORs, 1 WARNING, 2 NOTEs