[Yuima-commits] r771 - pkg/yuima/R
noreply at r-forge.r-project.org
noreply at r-forge.r-project.org
Thu Dec 16 21:01:17 CET 2021
Author: phoenix844
Date: 2021-12-16 21:01:17 +0100 (Thu, 16 Dec 2021)
New Revision: 771
Modified:
pkg/yuima/R/ae.R
Log:
Update ae.R
Modified: pkg/yuima/R/ae.R
===================================================================
--- pkg/yuima/R/ae.R 2021-12-16 19:20:38 UTC (rev 770)
+++ pkg/yuima/R/ae.R 2021-12-16 20:01:17 UTC (rev 771)
@@ -387,21 +387,21 @@
} else {
- # test <- parse(text = diffusion)
- #
- # env <- AE$par
- # env[[AE$eps.var]] <- 0
- # for(z in AE$z)
- # env[[z]] <- runif(n = 100, min = -999, max = 999)
- #
- # is.ok <- sapply(test, function(expr){
- # all(eval(expr, env)==0)
- # })
- #
- # if(!all(is.ok)){
- # stop('diffusion must vanish when evaluated at epsilon = 0')
- # }
+ test <- parse(text = diffusion)
+
+ env <- AE$par
+ env[[AE$eps.var]] <- 0
+ for(z in AE$z)
+ env[[z]] <- runif(n = 100, min = -999, max = 999)
+
+ is.ok <- suppressWarnings(sapply(test, function(expr){
+ all(eval(expr, env)==0, na.rm = TRUE)
+ }))
+ if(!all(is.ok)){
+ stop('diffusion must vanish when evaluated at epsilon = 0')
+ }
+
}
# building V...
More information about the Yuima-commits
mailing list