maechler@stat.math.ethz.ch
2002-Apr-22 10:30 UTC
[Rd] predict.*bSpline() bugs extrapolating for deriv >= 1 (PR#1473)
I've already fixed the bugs, but as with the last one, this is not critical enough to allow breaking current R-devel's code freeze. I hope I will have corrected it for 1.5.1.. ## Here is code reproducing the problems; ## I use try(.) whenever I know the current versions of R would ## give an error: library(splines) x <- c(1:3,5:6) y <- c(3:1,5:6) (isP <- interpSpline(x,y))# poly-spline representation (isB <- interpSpline(x,y, bSpl = TRUE))# B-spline repr. xo <- c(0, x, 10)# x + outside points options(digits = 4) for(der in 0:3) # deriv=3 fails! print(formatC(try(predict(isP, xo, deriv = der)$y), wid=7,format="f"), quote = FALSE) ##- Error in predict.npolySpline(isP, xo, deriv = der) : ##- subscript out of bounds ## Same for B-spline (instead of Polynom.): for(der in 0:3) # deriv=3 fails! print(formatC(try(predict(isB, xo, deriv = der)$y), wid=7,format="f"), quote = FALSE) ##- Error in predict.nbSpline(isB, xo, deriv = der) : ##- subscript out of bounds ## Here, also for deriv= 1 & 2, ## the value left to first proper knot is NA (and should not) <<< ! >>> ------ Martin Maechler <maechler@stat.math.ethz.ch> http://stat.ethz.ch/~maechler/ Seminar fuer Statistik, ETH-Zentrum LEO C16 Leonhardstr. 27 ETH (Federal Inst. Technology) 8092 Zurich SWITZERLAND phone: x-41-1-632-3408 fax: ...-1228 <>< -.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.- r-devel mailing list -- Read http://www.ci.tuwien.ac.at/~hornik/R/R-FAQ.html Send "info", "help", or "[un]subscribe" (in the "body", not the subject !) To: r-devel-request@stat.math.ethz.ch _._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._
maechler@stat.math.ethz.ch
2002-May-10 09:35 UTC
[Rd] predict.*bSpline() bugs extrapolating for deriv >= 1 (PR#1473)
>>>>> "MM" == Martin Maechler <maechler@stat.math.ethz.ch> writes:MM> I've already fixed the bugs, but as with the last one, this is MM> not critical enough to allow breaking current R-devel's code MM> freeze. I hope I will have corrected it for 1.5.1.. yes, done: the fix has been in R-patched for about 2 days now.. MM -.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.- r-devel mailing list -- Read http://www.ci.tuwien.ac.at/~hornik/R/R-FAQ.html Send "info", "help", or "[un]subscribe" (in the "body", not the subject !) To: r-devel-request@stat.math.ethz.ch _._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._