[Distr-commits] r1399 - in pkg/distr: . inst man tests/Examples

noreply at r-forge.r-project.org noreply at r-forge.r-project.org
Mon Nov 14 20:48:44 CET 2022


Author: ruckdeschel
Date: 2022-11-14 20:48:44 +0100 (Mon, 14 Nov 2022)
New Revision: 1399

Modified:
   pkg/distr/DESCRIPTION
   pkg/distr/inst/NEWS
   pkg/distr/man/0distr-package.Rd
   pkg/distr/man/MinMaximum-methods.Rd
   pkg/distr/man/RtoDPQ.Rd
   pkg/distr/man/RtoDPQ.d.Rd
   pkg/distr/man/qqplot.Rd
   pkg/distr/man/simplifyr-methods.Rd
   pkg/distr/tests/Examples/distr-Ex.Rout.save
Log:
[distr] Version 2.9.1 (new fuzz acc. to BDR) (in trunk)

Modified: pkg/distr/DESCRIPTION
===================================================================
--- pkg/distr/DESCRIPTION	2022-11-14 19:47:34 UTC (rev 1398)
+++ pkg/distr/DESCRIPTION	2022-11-14 19:48:44 UTC (rev 1399)
@@ -1,6 +1,6 @@
 Package: distr
-Version: 2.9.0
-Date: 2022-11-12
+Version: 2.9.1
+Date: 2022-11-14
 Title: Object Oriented Implementation of Distributions
 Description: S4-classes and methods for distributions.
 Authors at R: c(person("Florian", "Camphausen", role="ctb", comment="contributed as student in
@@ -20,4 +20,4 @@
 URL: http://distr.r-forge.r-project.org/
 LastChangedDate: {$LastChangedDate$}
 LastChangedRevision: {$LastChangedRevision$}
-VCS/SVNRevision: 1370
+VCS/SVNRevision: 1395

Modified: pkg/distr/inst/NEWS
===================================================================
--- pkg/distr/inst/NEWS	2022-11-14 19:47:34 UTC (rev 1398)
+++ pkg/distr/inst/NEWS	2022-11-14 19:48:44 UTC (rev 1399)
@@ -35,6 +35,8 @@
   (and detect that for prob in {0,1} Binom(size, prob) is in fact a Dirac distribution)
 + fixed some broken URLs and changed URLs from http to https where possible
   changed rstudio.com to posit.co
++ triggered by a mail by B. Ripley, for more significant Rdiff's, we delegated some blocks of
+  examples to ## IGNORE_RDIFF_BEGIN <code..> ## IGNORE_RDIFF_END
 
 ##############
 v 2.8.1

Modified: pkg/distr/man/0distr-package.Rd
===================================================================
--- pkg/distr/man/0distr-package.Rd	2022-11-14 19:47:34 UTC (rev 1398)
+++ pkg/distr/man/0distr-package.Rd	2022-11-14 19:48:44 UTC (rev 1399)
@@ -44,8 +44,8 @@
 \details{
 \tabular{ll}{
 Package: \tab distr \cr
-Version: \tab 2.9.0 \cr
-Date: \tab 2022-11-12 \cr
+Version: \tab 2.9.1 \cr
+Date: \tab 2022-11-14 \cr
 Depends: \tab R(>= 3.4), methods, graphics, startupmsg, sfsmisc \cr
 Suggests: \tab distrEx, svUnit (>= 0.7-11), knitr, distrMod, ROptEst \cr
 Imports: \tab stats, grDevices, utils, MASS \cr
@@ -52,7 +52,7 @@
 LazyLoad: \tab yes \cr
 License: \tab LGPL-3 \cr
 URL: \tab https://distr.r-forge.r-project.org/\cr
-VCS/SVNRevision: \tab 1370 \cr
+VCS/SVNRevision: \tab 1395 \cr
 }}
 \section{Classes}{
 Distribution classes have a slot \code{param} the class of which
@@ -349,4 +349,5 @@
 Z <- X+Y  # generates Law of corresponding independent variables
 p(Z)(0.2)
 r(Z)(1000)
-plot(Z+sin(Norm()))}
+plot(Z+sin(Norm()))
+}

Modified: pkg/distr/man/MinMaximum-methods.Rd
===================================================================
--- pkg/distr/man/MinMaximum-methods.Rd	2022-11-14 19:47:34 UTC (rev 1398)
+++ pkg/distr/man/MinMaximum-methods.Rd	2022-11-14 19:48:44 UTC (rev 1399)
@@ -76,10 +76,14 @@
 }}
 \seealso{\code{\link{Huberize}}, \code{\link{Truncate}}}
 \examples{
+## IGNORE_RDIFF_BEGIN
 plot(Maximum(Unif(0,1), Minimum(Unif(0,1), Unif(0,1))))
 plot(Minimum(Exp(4),4))
+## IGNORE_RDIFF_END
+
+\donttest{
 ## a sometimes lengthy example...
-\donttest{plot(Minimum(Norm(),Pois()))}
+plot(Minimum(Norm(),Pois()))}
 }
 \keyword{distribution}
 \keyword{methods}

Modified: pkg/distr/man/RtoDPQ.Rd
===================================================================
--- pkg/distr/man/RtoDPQ.Rd	2022-11-14 19:47:34 UTC (rev 1398)
+++ pkg/distr/man/RtoDPQ.Rd	2022-11-14 19:48:44 UTC (rev 1399)
@@ -49,8 +49,9 @@
 # returns density, cumulative distribution and quantile function of
 # squared standard normal distribution
 x$dfun(4)
+## IGNORE_RDIFF_BEGIN
 RtoDPQ(r = rn2, e = 5, n = 1024) # for a better result
-
+## IGNORE_RDIFF_END
 rp2 <- function(n){rpois(n, lambda = 1)^2}
 x <- RtoDPQ.d(r = rp2, e = 5)
 # returns density, cumulative distribution and quantile function of

Modified: pkg/distr/man/RtoDPQ.d.Rd
===================================================================
--- pkg/distr/man/RtoDPQ.d.Rd	2022-11-14 19:47:34 UTC (rev 1398)
+++ pkg/distr/man/RtoDPQ.d.Rd	2022-11-14 19:48:44 UTC (rev 1399)
@@ -41,10 +41,10 @@
 x <- RtoDPQ(r = rn2, e = 4, n = 512)
 # returns density, cumulative distribution and quantile function of
 # squared standard  normal distribution
-
 x$dfun(4)
+## IGNORE_RDIFF_BEGIN
 RtoDPQ(r = rn2, e = 5, n = 1024) # for a better result
-
+## IGNORE_RDIFF_END
 rp2 <- function(n){rpois(n, lambda = 1)^2}
 x <- RtoDPQ.d(r = rp2, e = 5)
 # returns density, cumulative distribution and quantile function of

Modified: pkg/distr/man/qqplot.Rd
===================================================================
--- pkg/distr/man/qqplot.Rd	2022-11-14 19:47:34 UTC (rev 1398)
+++ pkg/distr/man/qqplot.Rd	2022-11-14 19:48:44 UTC (rev 1399)
@@ -142,11 +142,13 @@
   Peter Ruckdeschel \email{peter.ruckdeschel at uni-oldenburg.de}
 }
 \examples{
+## IGNORE_RDIFF_BEGIN
 qqplot(Norm(15,sqrt(30)), Chisq(df=15))
 ## some discrete Distributions:
 P <- Pois(5)
 B <- Binom(size=2000,prob=5/2000)
 qqplot(B,P)
+## IGNORE_RDIFF_END
 \donttest{
 ## takes too much time for R CMD check --as-cran
 qqplot(B,P, nosym.pCI=TRUE)
@@ -155,8 +157,12 @@
 mylist <- UnivarLebDecDistribution(discretePart=Binom(3,.3), acPart=Norm(2,2),
                acWeight=11/20)
 mylist2 <- mylist+0.1
+
+## IGNORE_RDIFF_BEGIN
 qqplot(mylist,mylist2)
 qqplot(mylist,mylist2,exact.pCI=FALSE,exact.sCI=FALSE)
+## IGNORE_RDIFF_END
+
 \donttest{
 ## takes too much time for R CMD check --as-cran
 qqplot(mylist,mylist2,nosym.pCI=TRUE)

Modified: pkg/distr/man/simplifyr-methods.Rd
===================================================================
--- pkg/distr/man/simplifyr-methods.Rd	2022-11-14 19:47:34 UTC (rev 1398)
+++ pkg/distr/man/simplifyr-methods.Rd	2022-11-14 19:48:44 UTC (rev 1399)
@@ -22,10 +22,14 @@
 
 \examples{
 F <- ( Norm() + Binom() + Pois() + Exp() ) * 2 - 10
+## IGNORE_RDIFF_BEGIN
 system.time(r(F)(10^6))
+## IGNORE_RDIFF_END
 simplifyr(F, size = 10^6)
-system.time(r(F)(10^6))}
-
+## IGNORE_RDIFF_BEGIN
+system.time(r(F)(10^6))
+## IGNORE_RDIFF_END
+}
 \keyword{math}
 \keyword{distribution}
 \keyword{arith}

Modified: pkg/distr/tests/Examples/distr-Ex.Rout.save
===================================================================
--- pkg/distr/tests/Examples/distr-Ex.Rout.save	2022-11-14 19:47:34 UTC (rev 1398)
+++ pkg/distr/tests/Examples/distr-Ex.Rout.save	2022-11-14 19:48:44 UTC (rev 1399)
@@ -30,7 +30,7 @@
 
 Loading required package: sfsmisc
 :distr>  Object Oriented Implementation of Distributions (version
-:distr>  2.9.0)
+:distr>  2.9.1)
 :distr> 
 :distr>  Attention: Arithmetics on distribution objects are
 :distr>  understood as operations on corresponding random variables
@@ -223,6 +223,7 @@
 > plot(Z+sin(Norm()))
 > 
 > 
+> 
 > cleanEx()
 > nameEx("AbscontDistribution-class")
 > ### * AbscontDistribution-class
@@ -1649,15 +1650,14 @@
 > 
 > ### ** Examples
 > 
+> ## IGNORE_RDIFF_BEGIN
 > plot(Maximum(Unif(0,1), Minimum(Unif(0,1), Unif(0,1))))
 > plot(Minimum(Exp(4),4))
-> ## a sometimes lengthy example...
-> ## No test: 
-> plot(Minimum(Norm(),Pois()))
-> ## End(No test)
+> ## IGNORE_RDIFF_END
 > 
 > 
 > 
+> 
 > cleanEx()
 > nameEx("Naturals-class")
 > ### * Naturals-class
@@ -2002,6 +2002,7 @@
 > # squared standard normal distribution
 > x$dfun(4)
 [1] 0.02970112
+> ## IGNORE_RDIFF_BEGIN
 > RtoDPQ(r = rn2, e = 5, n = 1024) # for a better result
 Warning in .makeDNew(dxy$x, dxy$y, standM = "int") :
   'integrate()' threw an error ---result may be inaccurate.
@@ -2011,8 +2012,8 @@
                           d0 <-    log(df1(x))-log(stand)
                      else d0 <- df1(x) / stand
                      return (d0)}
-<bytecode: 0x0000026e095f0de8>
-<environment: 0x0000026e0c5b6f38>
+<bytecode: 0x0000022d496765d0>
+<environment: 0x0000022d4e1c7170>
 
 $pfun
 function (q, lower.tail = TRUE, log.p = FALSE) 
@@ -2027,7 +2028,7 @@
     else p0/nm
     return(p0)
 }
-<environment: 0x0000026e0c3a9a38>
+<environment: 0x0000022d4f17b5e0>
 
 $qfun
 function (p, lower.tail = TRUE, log.p = FALSE) 
@@ -2045,9 +2046,9 @@
     else q.l0(1 - p01)
     return(as.numeric(q0))
 }
-<environment: 0x0000026e12383518>
+<environment: 0x0000022d4f344678>
 
-> 
+> ## IGNORE_RDIFF_END
 > rp2 <- function(n){rpois(n, lambda = 1)^2}
 > x <- RtoDPQ.d(r = rp2, e = 5)
 > # returns density, cumulative distribution and quantile function of
@@ -2075,9 +2076,9 @@
   'integrate()' threw an error ---result may be inaccurate.
 > # returns density, cumulative distribution and quantile function of
 > # squared standard  normal distribution
-> 
 > x$dfun(4)
 [1] 0.02970112
+> ## IGNORE_RDIFF_BEGIN
 > RtoDPQ(r = rn2, e = 5, n = 1024) # for a better result
 Warning in .makeDNew(dxy$x, dxy$y, standM = "int") :
   'integrate()' threw an error ---result may be inaccurate.
@@ -2087,8 +2088,8 @@
                           d0 <-    log(df1(x))-log(stand)
                      else d0 <- df1(x) / stand
                      return (d0)}
-<bytecode: 0x0000026e095f0de8>
-<environment: 0x0000026e0ffb81a8>
+<bytecode: 0x0000022d496765d0>
+<environment: 0x0000022d4c5a06d0>
 
 $pfun
 function (q, lower.tail = TRUE, log.p = FALSE) 
@@ -2103,7 +2104,7 @@
     else p0/nm
     return(p0)
 }
-<environment: 0x0000026e0fd68ac8>
+<environment: 0x0000022d4c361938>
 
 $qfun
 function (p, lower.tail = TRUE, log.p = FALSE) 
@@ -2121,9 +2122,9 @@
     else q.l0(1 - p01)
     return(as.numeric(q0))
 }
-<environment: 0x0000026e0fd2baa0>
+<environment: 0x0000022d4e004338>
 
-> 
+> ## IGNORE_RDIFF_END
 > rp2 <- function(n){rpois(n, lambda = 1)^2}
 > x <- RtoDPQ.d(r = rp2, e = 5)
 > # returns density, cumulative distribution and quantile function of
@@ -3311,24 +3312,6 @@
 Warning in (new("standardGeneric", .Data = function (object)  :
   arithmetics on distributions are understood as operations on r.v.'s
 see 'distrARITH()'; for switching off this warning see '?distroptions'
-> ## No test: 
-> ## takes a little time
-> N ^ P
-An object of class "UnivarLebDecDistribution"
- --- a Lebesgue decomposed distribution:
-
-    Its discrete part (with weight 0.018000) is a
- Distribution Object of Class: Dirac
- location: 1
- This part is accessible with 'discretePart(<obj>)'.
-
-    Its absolutely continuous part (with weight 0.982000) is a
- Distribution Object of Class: AbscontDistribution
- This part is accessible with 'acPart(<obj>)'.
-Warning in (new("standardGeneric", .Data = function (object)  :
-  arithmetics on distributions are understood as operations on r.v.'s
-see 'distrARITH()'; for switching off this warning see '?distroptions'
-> ## End(No test)
 > 1.2 ^ N
 Distribution Object of Class: AbscontDistribution
 Warning in (new("standardGeneric", .Data = function (object)  :
@@ -3687,6 +3670,7 @@
 > 
 > ### ** Examples
 > 
+> ## IGNORE_RDIFF_BEGIN
 > qqplot(Norm(15,sqrt(30)), Chisq(df=15))
 dev.new(): using pdf(file="Rplots27.pdf")
 > ## some discrete Distributions:
@@ -3694,37 +3678,22 @@
 > B <- Binom(size=2000,prob=5/2000)
 > qqplot(B,P)
 dev.new(): using pdf(file="Rplots28.pdf")
-> ## No test: 
-> ## takes too much time for R CMD check --as-cran
-> qqplot(B,P, nosym.pCI=TRUE)
-dev.new(): using pdf(file="Rplots29.pdf")
-> ## End(No test)
+> ## IGNORE_RDIFF_END
 > ## some Lebesgue-Decomposed distributions:
 > mylist <- UnivarLebDecDistribution(discretePart=Binom(3,.3), acPart=Norm(2,2),
 +                acWeight=11/20)
 > mylist2 <- mylist+0.1
+> 
+> ## IGNORE_RDIFF_BEGIN
 > qqplot(mylist,mylist2)
+dev.new(): using pdf(file="Rplots29.pdf")
+> qqplot(mylist,mylist2,exact.pCI=FALSE,exact.sCI=FALSE)
 dev.new(): using pdf(file="Rplots30.pdf")
-> qqplot(mylist,mylist2,exact.pCI=FALSE,exact.sCI=FALSE)
-dev.new(): using pdf(file="Rplots31.pdf")
-> ## No test: 
-> ## takes too much time for R CMD check --as-cran
-> qqplot(mylist,mylist2,nosym.pCI=TRUE)
-dev.new(): using pdf(file="Rplots32.pdf")
-> ## some ac. distribution with a gap
-> mylist3 <- UnivarMixingDistribution(Unif(0,0.3),Unif(0.6,1),mixCoeff=c(0.8,0.2))
-> gaps(mylist3)
-          [,1]      [,2]
-[1,] 0.3000069 0.5999908
-> mylist4 <- UnivarMixingDistribution(Unif(0,0.3),Unif(0.6,1),mixCoeff=c(0.6,0.4))
-> qqplot(mylist3,mylist4)
-dev.new(): using pdf(file="Rplots33.pdf")
-> qqplot(mylist3,mylist4,nosym.pCI=TRUE)
-dev.new(): using pdf(file="Rplots34.pdf")
-> ## End(No test)
+> ## IGNORE_RDIFF_END
 > 
 > 
 > 
+> 
 > cleanEx()
 > nameEx("simplifyD-methods")
 > ### * simplifyD-methods
@@ -3827,15 +3796,20 @@
 > ### ** Examples
 > 
 > F <- ( Norm() + Binom() + Pois() + Exp() ) * 2 - 10
+> ## IGNORE_RDIFF_BEGIN
 > system.time(r(F)(10^6))
    user  system elapsed 
-    0.3     0.0     0.3 
+   0.33    0.00    0.33 
+> ## IGNORE_RDIFF_END
 > simplifyr(F, size = 10^6)
+> ## IGNORE_RDIFF_BEGIN
 > system.time(r(F)(10^6))
    user  system elapsed 
-   0.09    0.00    0.10 
+   0.08    0.00    0.08 
+> ## IGNORE_RDIFF_END
 > 
 > 
+> 
 > cleanEx()
 > nameEx("standardMethods")
 > ### * standardMethods
@@ -3868,7 +3842,7 @@
 > cleanEx()
 > options(digits = 7L)
 > base::cat("Time elapsed: ", proc.time() - base::get("ptime", pos = 'CheckExEnv'),"\n")
-Time elapsed:  90.1 4.19 104.75 NA NA 
+Time elapsed:  29.17 2.16 31.71 NA NA 
 > grDevices::dev.off()
 pdf 
  19 



More information about the Distr-commits mailing list