Skip to content

Commit

Permalink
Fixed accidental dim=lapply -> dim=sapply
Browse files Browse the repository at this point in the history
  • Loading branch information
sgaure committed Dec 9, 2019
1 parent 1f6b832 commit b4edd5d
Show file tree
Hide file tree
Showing 4 changed files with 7 additions and 10 deletions.
4 changes: 2 additions & 2 deletions DESCRIPTION
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
Package: chebpol
Version: 2.1-1
Date: 2019-09-06
Version: 2.1-2
Date: 2019-12-09
Title: Multivariate Interpolation
Authors@R: person("Simen", "Gaure", email="[email protected]", role=c("aut","cre"),
comment=c(ORCID="https://orcid.org/0000-0001-7251-8747"))
Expand Down
3 changes: 0 additions & 3 deletions configure
Original file line number Diff line number Diff line change
Expand Up @@ -1823,9 +1823,7 @@ fi
# some R standards
if test -n "${R_HOME}"; then
CC=`${R_HOME}/bin/R CMD config CC`
CPP=`${R_HOME}/bin/R CMD config CPP`
CFLAGS=`${R_HOME}/bin/R CMD config CFLAGS`
CPPFLAGS=`${R_HOME}/bin/R CMD config CPPFLAGS`
fi
if test "${use_check}" = "yes"; then :
Expand Down Expand Up @@ -3073,7 +3071,6 @@ fi
cat >confcache <<\_ACEOF
# This file is a shell script that caches the results of configure
# tests run on this system so they can be shared between configure
Expand Down
2 changes: 1 addition & 1 deletion tests/all.R
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@ su <- seq(0,1,length.out=11)
grid <- list(su,su^2,su^3)
dims <- lapply(grid,length)

fv <- structure(apply(expand.grid(grid),1,f),dim=lapply(grid,length))
fv <- structure(apply(expand.grid(grid),1,f),dim=sapply(grid,length))
ch <- ipol(fv,grid=grid,method='general')
s <- runif(3)
cat('true:',f(s),'appx:',ch(s),'\n')
Expand Down
8 changes: 4 additions & 4 deletions tests/all.Rout.save
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@

R Under development (unstable) (2018-08-19 r75170) -- "Unsuffered Consequences"
Copyright (C) 2018 The R Foundation for Statistical Computing
R Under development (unstable) (2019-12-09 r77544) -- "Unsuffered Consequences"
Copyright (C) 2019 The R Foundation for Statistical Computing
Platform: x86_64-pc-linux-gnu (64-bit)

R is free software and comes with ABSOLUTELY NO WARRANTY.
Expand Down Expand Up @@ -113,7 +113,7 @@ true: 1.414461 appx: 1.418184
> grid <- list(su,su^2,su^3)
> dims <- lapply(grid,length)
>
> fv <- structure(apply(expand.grid(grid),1,f),dim=lapply(grid,length))
> fv <- structure(apply(expand.grid(grid),1,f),dim=sapply(grid,length))
> ch <- ipol(fv,grid=grid,method='general')
> s <- runif(3)
> cat('true:',f(s),'appx:',ch(s),'\n')
Expand Down Expand Up @@ -225,4 +225,4 @@ In (function (val, knots, k = 2, normalize = NA, nowarn = FALSE, :
>
> proc.time()
user system elapsed
5.437 0.234 1.639
8.386 0.297 1.932

0 comments on commit b4edd5d

Please sign in to comment.