[Distr-commits] r1443 - in pkg/setRNG: . R

noreply at r-forge.r-project.org noreply at r-forge.r-project.org
Sun Feb 18 15:52:32 CET 2024


Author: pgilbert
Date: 2024-02-18 15:52:31 +0100 (Sun, 18 Feb 2024)
New Revision: 1443

Modified:
   pkg/setRNG/DESCRIPTION
   pkg/setRNG/NEWS
   pkg/setRNG/R/setRNG.R
Log:
Removed is.R() and other small adjustments found by newer CRAN checks.

Modified: pkg/setRNG/DESCRIPTION
===================================================================
--- pkg/setRNG/DESCRIPTION	2024-02-13 14:24:06 UTC (rev 1442)
+++ pkg/setRNG/DESCRIPTION	2024-02-18 14:52:31 UTC (rev 1443)
@@ -1,5 +1,5 @@
 Package: setRNG
-Version: 2015.7-1
+Version: 2024.2-1
 Title: Set (Normal) Random Number Generator and Seed
 Description: Provides utilities to help set and record the setting of
 	the seed and the uniform and normal generators used when a random

Modified: pkg/setRNG/NEWS
===================================================================
--- pkg/setRNG/NEWS	2024-02-13 14:24:06 UTC (rev 1442)
+++ pkg/setRNG/NEWS	2024-02-18 14:52:31 UTC (rev 1443)
@@ -1,5 +1,11 @@
-Changes in setRNG version 20xx.x-x
+Changes in setRNG version 2024.2-1
 
+   o	Removed is.R() and replaced with TRUE since is.R() is deprecated in R 4.4.0.
+
+Changes in setRNG version 2022.4-1
+
+   o	Added importFrom("stats", "runif", "rnorm") to NAMESPACE file.
+
    o	Fixed Rbuildignore so that files from building vignettes are 
     	not omitted in the package build.	
 

Modified: pkg/setRNG/R/setRNG.R
===================================================================
--- pkg/setRNG/R/setRNG.R	2024-02-13 14:24:06 UTC (rev 1442)
+++ pkg/setRNG/R/setRNG.R	2024-02-18 14:52:31 UTC (rev 1443)
@@ -66,7 +66,9 @@
 
 random.number.test <- function()
  {cat("Random number generator tests ...")
-  if (is.R())  
+#  'is.R' is deprecated in R 4.3.3 2024-02-02
+#  if (is.R())  
+  if (TRUE)  
      {test.seed<- 979   #previous to R 1.0.0: c( 979, 1479, 1542) 
       # values from 0.49 beta
       #test.valueU <-c(5.693354055333957e-01,1.051357751852140e-01,
@@ -91,7 +93,7 @@
       test.valueN <- c(0.2947980960879867, 0.5315740209738240,
             -0.7439218830522146, -0.9861002105572579, -0.3542773118879623)
      }
-  if (!is.R()) 
+  if (!TRUE) 
      {# above should really be if (is.Splus()) 
       test.seed<- c(37, 39, 39, 4, 7, 2, 27, 58, 38, 15, 32, 2)
       test.valueU.S <- c(0.4299328043125570, 0.3092006836086512,
@@ -104,7 +106,7 @@
   on.exit(setRNG(old.seed))
 
   ok <- TRUE
-if ( !is.R())
+if ( !TRUE)
  {if (1e-14 < max(abs(runif(5)-test.valueU.S)))
     {warning("The default runif number generator has been changed.")
      ok <- FALSE
@@ -117,7 +119,7 @@
      ok <- FALSE
     }
  }
-if ( is.R())
+if ( TRUE)
  {if (as.numeric(version$major)+0.1*as.numeric(version$minor) > 1.62 )
   {if (1e-14 < max(abs(runif(5)-test.valueU)))
     {warning("The default runif number generator has been changed.")



More information about the Distr-commits mailing list