Skip to content

Commit 54b61c7

Browse files
authored
non-vec test fun
1 parent c70ab24 commit 54b61c7

File tree

2 files changed

+4
-4
lines changed

2 files changed

+4
-4
lines changed

src/test/cases.Morris/sobol.R

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -9,9 +9,9 @@ f <- function(X) {
99
a <- c(0, 1, 4.5, 9, 99, 99, 99, 99)
1010
y <- 1
1111
for (j in 1:8) {
12-
y <- y * (abs(4 * X[, j] - 2) + a[j]) / (1 + a[j])
12+
y <- y * (abs(4 * X[j] - 2) + a[j]) / (1 + a[j])
1313
}
14-
matrix(y,nrow=nrow(X))
14+
y
1515
}
1616

1717
input.f = list(

src/test/cases/sobol.R

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -9,9 +9,9 @@ f <- function(X) {
99
a <- c(0, 1, 4.5, 9, 99, 99, 99, 99)
1010
y <- 1
1111
for (j in 1:8) {
12-
y <- y * (abs(4 * X[, j] - 2) + a[j]) / (1 + a[j])
12+
y <- y * (abs(4 * X[j] - 2) + a[j]) / (1 + a[j])
1313
}
14-
matrix(y,nrow=nrow(X))
14+
y
1515
}
1616

1717
input.f = list(

0 commit comments

Comments
 (0)