From 0b897e72d68a61b847052e7f60a3c4de7d891f9e Mon Sep 17 00:00:00 2001 From: Sergey Kucheryavskiy Date: Mon, 26 Apr 2021 13:13:43 +0200 Subject: [PATCH 1/2] fixed an issue in simpls implementation which lead to wrong check results on M1 --- R/pls.R | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/R/pls.R b/R/pls.R index d3abfab..c185a84 100755 --- a/R/pls.R +++ b/R/pls.R @@ -1497,7 +1497,7 @@ pls.simpls <- function(x, y, ncomp, cv = FALSE) { c <- as.numeric(crossprod(w, (M %*% w))) # stop cycle since c-value is very small and can result in singular matrix - if (c < .Machine$longdouble.eps) { + if (c < .Machine$double.eps) { n <- n - 1 warning(paste0( "PLS can not compute more than ", n, " components (eigenvalues are too small). " From f32679409532f7007ff982c98f153304b44ac6b7 Mon Sep 17 00:00:00 2001 From: Sergey Kucheryavskiy Date: Mon, 26 Apr 2021 13:15:11 +0200 Subject: [PATCH 2/2] changes in supplementary files for coming release --- DESCRIPTION | 4 ++-- NEWS.md | 5 +++++ README.md | 6 +++--- 3 files changed, 10 insertions(+), 5 deletions(-) diff --git a/DESCRIPTION b/DESCRIPTION index 89fcca7..3bbf9c8 100644 --- a/DESCRIPTION +++ b/DESCRIPTION @@ -1,7 +1,7 @@ Package: mdatools Title: Multivariate Data Analysis for Chemometrics -Version: 0.11.4 -Date: 2021-04-23 +Version: 0.11.5 +Date: 2021-04-26 Author: Sergey Kucheryavskiy () Maintainer: Sergey Kucheryavskiy Description: Projection based methods for preprocessing, diff --git a/NEWS.md b/NEWS.md index 14139a7..df6d10e 100755 --- a/NEWS.md +++ b/NEWS.md @@ -1,3 +1,8 @@ +v.0.11.5 +======== + +* fix for an issue in PLS SIMPLS implementation (incorrect use of `Machine$longdouble.eps`), which lead to an error when the package is tested on Apple M1. + v.0.11.4 ======== diff --git a/README.md b/README.md index 1577855..5dae6cd 100755 --- a/README.md +++ b/README.md @@ -19,16 +19,16 @@ If you want to cite the package, please use the following: Sergey Kucheryavskiy, What is new ----------- -Latest release (0.11.4) is available both from GitHub and CRAN. You can see the full list of changes [here](NEWS.md). The Bookdown tutorial has been also updated and contains the description of new methods added in the last release. +Latest release (0.11.5) is available both from GitHub and CRAN. You can see the full list of changes [here](NEWS.md). The Bookdown tutorial has been also updated and contains the description of new methods added in the last release. How to install -------------- -The package is available from CRAN by usual installing procedure. However, due to restrictions in CRAN politics regarding number of submissions (one in 3-4 month), mostly major releases will be published there (with 2-3 weeks delay after GitHub release as more thorough testing is needed). You can [download](https://github.com/svkucheryavski/mdatools/releases) a zip-file with source package and install it using the `install.packages` command, e.g. if the downloaded file is `mdatools_0.11.4.tar.gz` and it is located in a current working directory, just run the following: +The package is available from CRAN by usual installing procedure. However, due to restrictions in CRAN politics regarding number of submissions (one in 3-4 month), mostly major releases will be published there (with 2-3 weeks delay after GitHub release as more thorough testing is needed). You can [download](https://github.com/svkucheryavski/mdatools/releases) a zip-file with source package and install it using the `install.packages` command, e.g. if the downloaded file is `mdatools_0.11.5.tar.gz` and it is located in a current working directory, just run the following: ``` -install.packages("mdatools_0.11.4.tar.gz") +install.packages("mdatools_0.11.5.tar.gz") ``` If you have `devtools` package installed, the following command will install the current developer version from the master branch of GitHub repository (do not forget to load the `devtools` package first):