[r-cran-gam] 14/20: Imported Upstream version 1.14

Andreas Tille tille at debian.org
Fri Dec 16 14:32:11 UTC 2016


This is an automated email from the git hooks/post-receive script.

tille pushed a commit to branch master
in repository r-cran-gam.

commit 8db97d456d866cf91667cfa14ba2951a5a721bd4
Author: Andreas Tille <tille at debian.org>
Date:   Fri Dec 16 13:42:01 2016 +0100

    Imported Upstream version 1.14
---
 ChangeLog         |  7 ++++++-
 DESCRIPTION       |  8 +++----
 MD5               | 22 ++++++++++----------
 NAMESPACE         |  3 ++-
 R/gam.R           | 43 +++++++++++++++++++++++---------------
 R/gam.lo.R        |  9 ++++++--
 R/lo.wam.R        | 62 ++++++++++++++++++++++++++++++-------------------------
 R/subset.smooth.R |  8 +++----
 man/gam.Rd        | 26 +++++++++++------------
 man/gam.exact.Rd  |  7 +++----
 src/Makevars      |  1 +
 src/loessc.c      |  2 +-
 12 files changed, 112 insertions(+), 86 deletions(-)

diff --git a/ChangeLog b/ChangeLog
index b9612e0..d90f755 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,8 @@
+2016-09-09   Trevor Hastie <hastie at stanford.edu> version 1.14
+	* fixed bug in gam when NAs are in data (model.frame does not
+	behave as stated, so I had to make a work around)
+	* gam models with lo(, degree=2) where getting segfaults. Enlarged
+	the work space and this appears to have fixed the problem.
 2013-08-02   Trevor Hastie <hastie at stanford.edu> version 1.09
 	* improved step.gam significantly (it works now for eg, the spam data); added parallel option
 	* man/step.gam  updated
@@ -5,4 +10,4 @@
 	* man/scope.gam  added
 	* R/summary.gam split up the anova to two anovas - one for the parametric, and one for nonparametric
 ###	Note that this starts from gam 1.09
-	
+
diff --git a/DESCRIPTION b/DESCRIPTION
index 138210e..a1d3494 100644
--- a/DESCRIPTION
+++ b/DESCRIPTION
@@ -1,8 +1,8 @@
 Package: gam
 Type: Package
 Title: Generalized Additive Models
-Date: 2015-05-11
-Version: 1.12
+Date: 2016-09-09
+Version: 1.14
 Author: Trevor Hastie
 Description: Functions for fitting and working with generalized
 		additive models, as described in chapter 7 of "Statistical Models in
@@ -13,6 +13,6 @@ Depends: stats, splines, foreach
 Suggests: akima
 License: GPL-2
 NeedsCompilation: yes
-Packaged: 2015-05-13 05:57:11 UTC; hastie
+Packaged: 2016-09-10 01:16:06 UTC; hastie
 Repository: CRAN
-Date/Publication: 2015-05-13 08:49:49
+Date/Publication: 2016-09-10 18:02:23
diff --git a/MD5 b/MD5
index eb1c932..8807281 100644
--- a/MD5
+++ b/MD5
@@ -1,17 +1,17 @@
-c95bed4e0f0a9c7ce468d8b0c3b86c99 *ChangeLog
-b30ae6370f11ae1cf2cd18952809b7a7 *DESCRIPTION
+007fac2c4f6581a2d69502475c0e3cc4 *ChangeLog
+6cde3d6c4c2975c8daedb554d5e2107c *DESCRIPTION
 af77f82fb0aa5e383808c5f36aa47066 *INDEX
-e8786be90e351f6e1f9c7bc9b853176d *NAMESPACE
+377c0a46d32ba682ba6da320a828ef12 *NAMESPACE
 f2cdce15d203d42d6ea559059e7f5820 *R/anova.gam.R
 cb6e56d47338bc65c4f35ca2b45b8968 *R/anova.gamlist.R
 c67ddb150e807c4a0ef77acf132c1021 *R/as.anova.R
 996bcecc62a9687cb77863e45830a000 *R/as.data.frame.lo.smooth.R
 69d4bccf3afc7a1a9fd2b5d8b2f60fec *R/assign.list.R
-155300acde3149437b0f3650a1772273 *R/gam.R
+6299e47cf266e256cacf0a45a29a14ee *R/gam.R
 6f9d6d8a11d7b20d791233f1ed3445dc *R/gam.control.R
 2c633d79441282175358f1a0c148bd50 *R/gam.exact.R
 363a8ceb73c42777fa19e1741561b6cd *R/gam.fit.R
-bd96ac15ba688c863f09f0e632a411f2 *R/gam.lo.R
+f47a64e337008b4320396a88ba5cdb34 *R/gam.lo.R
 946d0c85f06753f768700803d197c247 *R/gam.match.R
 526f48fabc38d73bef43169182a7051a *R/gam.nlchisq.R
 0825a9bc8c213e3ddfc262178239a48f *R/gam.random.R
@@ -30,7 +30,7 @@ d9e47c37ce11bb5d36eb65e7af17debc *R/gplot.matrix.R
 5fc7caa79f441edc92935788f38444b2 *R/gplot.numeric.R
 9c06038289b4ccad8383f467b73ad06b *R/labels.gam.R
 093d17804fa5ce90f12cdeb4f9fbcf6a *R/lo.R
-f8e577af7d28bdf5252ef489f4cb824d *R/lo.wam.R
+7ec421436e0baf060ae08ab07bd53dd7 *R/lo.wam.R
 901999a84e9e5db5552b706a99fcc303 *R/na.gam.replace.R
 a82abbfbf9d226c04290dd721e1d8b51 *R/newdata.predict.gam.R
 39cfb671132d4928c0a77a79edb1967d *R/onAttach.R
@@ -47,7 +47,7 @@ c318b1f9d34fda3e660a9af01b86c830 *R/random.R
 1478722abc4269fede0d572840c0cfbe *R/s.R
 c0ea33636dd8d8e8088a173fd5670d7f *R/s.wam.R
 564df4d615c924b58ed9168554fa3945 *R/step.gam.R
-9c1302d138d07b10f17c27765bd87955 *R/subset.smooth.R
+8f34f93005ef6dd0d5f6bfe419daf930 *R/subset.smooth.R
 0e3af75530812309d9fb9d4696438046 *R/summary.gam.R
 5cc7658080bc925bb5fc11172d78fb41 *R/ylim.scale.R
 ba66638e3de17b868b4d98dffe95009d *data/gam.data.RData
@@ -60,10 +60,10 @@ a009bd4d2232ec7cc19b9d7d10280ffb *inst/ratfor/backlo.r
 58295734adaaee3561f298e7c0b93eee *inst/ratfor/splsm.r
 b86dc231f80eb84973ab3ab5f179e423 *man/anova.gam.Rd
 d20a1c1617715af04e1e911a2ce4ba0d *man/gam-internal.Rd
-05847ec1f125a8fe182f6e680d05183c *man/gam.Rd
+a0df1eb31b935ea7bb4293b42d7afea7 *man/gam.Rd
 5167ecd9baaea501d766f87b4e22cf20 *man/gam.control.Rd
 d3c27998fb1cdce4cb00703557f1138d *man/gam.data.Rd
-f317aafb77e4b02b30e81786fb663c5f *man/gam.exact.Rd
+7bf56c13f047b3e9e849f22767eb5b79 *man/gam.exact.Rd
 fc57a2513d84056abd88a39ac9bc352d *man/gam.scope.Rd
 dd3553bd8578858873bd1384b000273a *man/kyphosis.Rd
 2bac0339dc32adb38b491c7ec1cd8601 *man/lo.Rd
@@ -72,7 +72,7 @@ a79905d34d4d93cb9939329b7cc8f507 *man/plot.gam.Rd
 7de080b0a4e684b2a2b4e26e17fe38d8 *man/predict.gam.Rd
 1825ff921f39de62c26f66960f98da7b *man/s.Rd
 f77c2a626622ba85614fac57d2b896b1 *man/step.gam.Rd
-f80de2889856cba0512e5377926af1aa *src/Makevars
+2bf8ef7e1425c36f4be16667cdcdd3b3 *src/Makevars
 2fa4c7011c2bc0f7449ae151d5cc44ae *src/Makevars.win
 45061d1eb26bda41c4c458126dd303da *src/backfit.f
 7205467d48f1b2f05d6b830aa34afac1 *src/backlo.f
@@ -81,7 +81,7 @@ f80de2889856cba0512e5377926af1aa *src/Makevars
 40c1f6b57d6c3a03a1d972f009c5e5df *src/bvalus.f
 114d8313198201d0f01482982e5e8de7 *src/linear.f
 6b4fde12653de078154a99510fed6d64 *src/lo.f
-388f5201bdc80e4c25a575f4810915d6 *src/loessc.c
+f063989e94567ac0f957371a2fd6333c *src/loessc.c
 425c0bc459b1dee59d08e5cd6c28d89c *src/loessf.f
 6ada085e39fd48968fcd79368c0ccddd *src/modreg.h
 e1c0a8ef61f04b6239ff2ea6874be92d *src/qsbart.f
diff --git a/NAMESPACE b/NAMESPACE
index 8230250..a59ce5b 100644
--- a/NAMESPACE
+++ b/NAMESPACE
@@ -2,7 +2,8 @@ useDynLib(gam)
 import(stats)
 import(splines)
 import(foreach)
-importFrom(utils,head,tail,packageDescription)
+importFrom("graphics", "axis", "lines", "mtext", "persp", "plot", "points", "rug", "segments")
+importFrom(utils,head,tail,packageDescription,menu)
 export(general.wam,anova.gamlist,as.anova,as.data.frame.lo.smooth,assign.list,gam,gam.control,gam.exact,gam.fit,gamlist,gam.lo,gam.match,gam.nlchisq,gam.random,gam.s,gam.scope,gam.slist,gam.sp,gam.wlist,gplot,gplot.default,gplot.factor,gplot.list,gplot.matrix,gplot.numeric,lo,lo.wam,na.gam.replace,newdata.predict.gam,plot.gam,polylo,predict.gam,random,s,s.wam,ylim.scale,step.gam,summary.gam)
 S3method("[",smooth)
 S3method(labels,gam)
diff --git a/R/gam.R b/R/gam.R
index a5e22e1..16c1e26 100644
--- a/R/gam.R
+++ b/R/gam.R
@@ -1,55 +1,64 @@
 "gam" <-
-  function(formula, family = gaussian, data, 
+  function(formula, family = gaussian, data,
            weights, subset, na.action, start = NULL, etastart, mustart, control = gam.control(...),
            model = TRUE, method="glm.fit", x = FALSE, y = TRUE, ...)
 {
   call <- match.call()
-  if (is.character(family)) 
+  if (is.character(family))
     family <- get(family, mode = "function", envir = parent.frame())
-  if (is.function(family)) 
+  if (is.function(family))
     family <- family()
   if (is.null(family$family)) {
     print(family)
     stop("`family' not recognized")
   }
-  if (missing(data)) 
+  if (missing(data))
     data <- environment(formula)
   mf <- match.call(expand.dots = FALSE)
-  m <- match(c("formula", "data", "subset", "weights", "na.action", 
-               "etastart", "mustart", "offset"), names(mf), 0)
-  mf <- mf[c(1, m)]
+  ## m <- match(c("formula", "data", "subset", "weights", "na.action",
+  ##              "etastart", "mustart", "offset"), names(mf), 0L)
+ m <- match(c("formula", "data", "subset", "weights",
+              "etastart", "mustart", "offset"), names(mf), 0L)
+  mf <- mf[c(1L, m)]
+  mf$na.action=quote(na.pass)## need to do this because model frame is not subsetting properly
   mf$drop.unused.levels <- TRUE
-  mf[[1]] <- as.name("model.frame")
+  mf[[1L]] <- quote(stats::model.frame)
   mt <- if(missing(data)) terms(formula, gam.slist) else terms(formula,gam.slist,data = data)
-  mf$formula<-mt                                                          
+  mf$formula<-mt
   mf <- eval(mf, parent.frame())
-   switch(method, model.frame = return(mf), glm.fit = 1, glm.fit.null = 1, 
+  if(missing(na.action)){
+      naa=getOption("na.action","na.fail")
+      na.action=get(naa)
+      }
+  mf=na.action(mf)###because this was not done properly before
+  mt=attributes(mf)[["terms"]]# the predvars are added here, while not before
+    switch(method, model.frame = return(mf), glm.fit = 1, glm.fit.null = 1,
          stop("invalid `method': ", method))
 
 
   Y <- model.response(mf, "any")
-  X <- if (!is.empty.model(mt)) 
+  X <- if (!is.empty.model(mt))
     model.matrix(mt, mf, contrasts)
   else matrix(, NROW(Y), 0)
   weights <- model.weights(mf)
   offset <- model.offset(mf)
-  if (!is.null(weights) && any(weights < 0)) 
+  if (!is.null(weights) && any(weights < 0))
     stop("Negative wts not allowed")
-  if (!is.null(offset) && length(offset) != NROW(Y)) 
-    stop("Number of offsets is ", length(offset), ", should equal ", 
+  if (!is.null(offset) && length(offset) != NROW(Y))
+    stop("Number of offsets is ", length(offset), ", should equal ",
          NROW(Y), " (number of observations)")
   mustart <- model.extract(mf, "mustart")
   etastart <- model.extract(mf, "etastart")
 fit<-gam.fit(x=X,y=Y,smooth.frame=mf,weights=weights,start=start,
              etastart=etastart,mustart=mustart,
              offset=offset,family=family,control=control)
-  
+
 ### If both an offset and intercept are present, iterations are needed to
 ### compute the Null deviance; these are done here
 ###
   if(length(offset) && attr(mt, "intercept")>0) {
-    fit$null.dev <- glm.fit(x = X[, "(Intercept)", drop = FALSE], 
-               y = Y, weights = weights, offset = offset, family = family, 
+    fit$null.dev <- glm.fit(x = X[, "(Intercept)", drop = FALSE],
+               y = Y, weights = weights, offset = offset, family = family,
                control = control[c("epsilon","maxit","trace")], intercept = TRUE)$deviance
   }
     if(model) fit$model <- mf
diff --git a/R/gam.lo.R b/R/gam.lo.R
index ea94c67..bc6a414 100644
--- a/R/gam.lo.R
+++ b/R/gam.lo.R
@@ -17,9 +17,14 @@ function(x, y, w = rep(1, length(y)), span = 0.5, degree = 1, ncols = p, xeval
 	storage.mode(ncols) <- "integer"
 	o <- gam.match(x)
 	nef <- o$nef
+#	nvmax <- max(200,nef)
 	nvmax <- as.integer(200 + 300 * (1 - 1/log(max(c(nef - 200, 3)))))
-	liv <- as.integer(50 + (2^ncols + 4) * nvmax + 2 * nef)
-	lv <- as.integer(50 + (3 * ncols + 3) * nvmax + nef + (ifelse(degree ==
+#	liv <- as.integer(50 + (2^ncols + 4) * nvmax + 2 * nef)
+#	lv <- as.integer(50 + (3 * ncols + 3) * nvmax + nef + (ifelse(degree ==
+#		2, ((ncols + 2) * (ncols + 1))/2, ncols + 1) + 2) * (nef * span +
+#		1))
+	liv <- as.integer(100 + (2^ncols + 4) * nvmax + 2 * nef)
+	lv <- as.integer(100 + (3 * ncols + 3) * nvmax + nef + (ifelse(degree ==
 		2, ((ncols + 2) * (ncols + 1))/2, ncols + 1) + 2) * (nef * span +
 		1))
 	fit <- .Fortran("lo0",
diff --git a/R/lo.wam.R b/R/lo.wam.R
index 8825c2c..9d2a4c2 100644
--- a/R/lo.wam.R
+++ b/R/lo.wam.R
@@ -15,38 +15,44 @@ function(x, y, w, s, which, smooth.frame, maxit = 30, tol = 1e-7, trace = FALSE,
 		span <- sapply(atts, "[[", "span")
 		degree <- sapply(atts, "[[", "degree")
 		nvars <- sapply(atts, "[[", "ncols")
-		ndim <- sapply(atts, "[[", "dim")[2.,  ]
-		npetc <- as.integer(c(dx, length(which), 0., maxit, 0.))
+		ndim <- sapply(atts, "[[", "dim")[2,  ]
+		npetc <- as.integer(c(dx, length(which), 0, maxit, 0))
 		nef <- smooth.frame$nef
-		nvmax <- 200. + 300. * (1. - 1./log(apply(cbind(nef - 200.,
-			3.), 1., max)))
-		nspar <- (nef * span + 1.)
-		liv <- 50. + (2.^nvars + 4.) * nvmax + 2. * nef
-		lv <- 50. + (3. * nvars + 3.) * nvmax + nef + (ifelse(degree ==
-			2., ((nvars + 2.) * (nvars + 1.))/2., nvars + 1.) +
-			2.) * nspar
+		nvmax <- 200 + 300 * (1 - 1/log(apply(cbind(nef - 200,
+			3), 1, max)))
+#		nvmax <- pmax(200,nef)
+		nspar <- (nef * span + 1)
+#		liv <- 50 + (2^nvars + 4) * nvmax + 2 * nef
+#		lv <- 50 + (3 * nvars + 3) * nvmax + nef + (ifelse(degree ==
+#			2, ((nvars + 2) * (nvars + 1))/2, nvars + 1) +
+#			2) * nspar
+		liv <- 100 + (2^nvars + 4) * nvmax + 2 * nef
+		lv <- 100 + (3 * nvars + 3) * nvmax + nef + (ifelse(degree ==
+			2, ((nvars + 2) * (nvars + 1))/2, nvars + 1) +
+			2) * nspar
 		LL <- nspar * nvmax
 		liv <- liv + LL
-		lv <- lv + (nvars + 1.) * LL
-		which <- sapply(which, "[", 1.)
-		wddnfl <- cbind(unlist(which), nvars, ndim, degree, nef, liv,
-			lv, nvmax)
+		lv <- lv + (nvars + 1) * LL
+		which <- sapply(which, "[", 1)
+		wddnfl <- cbind(unlist(which), nvars, ndim, degree, nef, liv=ceiling(liv),
+			lv=ceiling(lv), nvmax=ceiling(nvmax))
 		storage.mode(wddnfl) <- "integer"
 		spatol <- as.double(c(span, tol))
-		nwork <- 9. * dx[1.] + sum(nef * (nvars + ndim + 4.) + 5. +
-			3. * ndim)
-		liv <- sum(liv)
-		lv <- sum(lv)
-		smooth.frame <- c(smooth.frame, list(npetc = npetc, wddnfl = 
+		nwork <- 9 * dx[1] + sum(nef * (nvars + ndim + 4) + 5 +
+                                         3 * ndim)
+                ###I put in a factor 2 here because I dont know what else to do to solved this seg fault
+		liv <- as.integer(2*ceiling(sum(liv)))
+		lv <- as.integer(2*ceiling(sum(lv)))
+		smooth.frame <- c(smooth.frame, list(npetc = npetc, wddnfl =
 			wddnfl, spatol = spatol,niwork=2*sum(nvars), nwork = nwork, liv = liv,
 			lv = lv))
 	}
 	else first <- FALSE
 	storage.mode(y) <- "double"
 	storage.mode(w) <- "double"
-	n <- smooth.frame$npetc[1.]
-	p <- smooth.frame$npetc[2.]
-	q <- smooth.frame$npetc[3.]
+	n <- smooth.frame$npetc[1]
+	p <- smooth.frame$npetc[2]
+	q <- smooth.frame$npetc[3]
 	fit <- .Fortran("baklo",
 		x,
 		y = y,
@@ -63,7 +69,7 @@ function(x, y, w, s, which, smooth.frame, maxit = 30, tol = 1e-7, trace = FALSE,
 		df = double(q),
 		qr = x,
 		qraux = double(p),
-		qpivot = as.integer(1.:p),
+		qpivot = as.integer(1:p),
                 effects=double(n),
 		integer(smooth.frame$liv),
 		double(smooth.frame$lv),
@@ -71,9 +77,9 @@ function(x, y, w, s, which, smooth.frame, maxit = 30, tol = 1e-7, trace = FALSE,
 		double(smooth.frame$nwork),
                         PACKAGE="gam")
 
-	nit <- fit$npetc[4.]
-	qrank <- fit$npetc[6.]
-	if((nit == maxit) & maxit > 1.)
+	nit <- fit$npetc[4]
+	qrank <- fit$npetc[6]
+	if((nit == maxit) & maxit > 1)
 		warning(paste("lo.wam convergence not obtained in ", maxit,
 			" iterations"))
 	names(fit$df) <- dimnames(s)[[2]]
@@ -83,10 +89,10 @@ function(x, y, w, s, which, smooth.frame, maxit = 30, tol = 1e-7, trace = FALSE,
         effects<-fit$effects
         r1 <- seq(len = qrx$rank)
         dn <- colnames(x)
-        if (is.null(dn)) 
+        if (is.null(dn))
           dn <- paste("x", 1:p, sep = "")
         names(effects) <- c(dn[qrx$pivot[r1]], rep.int("", n - qrx$rank))
-	rl <- list(coefficients = fit$beta, residuals = fit$y - fit$eta, 
+	rl <- list(coefficients = fit$beta, residuals = fit$y - fit$eta,
                    fitted.values = fit$eta,
                    effects=effects, weights=w, rank=qrank,
                    assign=attr(x,"assign"),
@@ -94,7 +100,7 @@ function(x, y, w, s, which, smooth.frame, maxit = 30, tol = 1e-7, trace = FALSE,
                    smooth = fit$s,
                    nl.df = fit$df
                    )
-	rl$df.residual <- n - qrank - sum(rl$nl.df) - sum(fit$w == 0.)
+	rl$df.residual <- n - qrank - sum(rl$nl.df) - sum(fit$w == 0)
 	if(se)
 		rl <- c(rl, list(var = fit$var))
 	c(list(smooth.frame = smooth.frame), rl)
diff --git a/R/subset.smooth.R b/R/subset.smooth.R
index ae33497..cecc5bd 100644
--- a/R/subset.smooth.R
+++ b/R/subset.smooth.R
@@ -10,13 +10,13 @@ function(x, ..., drop = FALSE)
 	y <- x[..., drop = drop]
 	if(!is.null(nas <- ats$NAs)) {
 		if(is.null(d <- dim(x)))
-			d <- c(length(x), 1.)
-		navec <- array(logical(d[1.]), d)
+			d <- c(length(x), 1)
+		navec <- array(logical(d[1]), d)
 		navec[nas,  ] <- TRUE
 		navec <- navec[...]
-		nas <- if(is.null(dim(navec))) navec else navec[, 1.]
+		nas <- if(is.null(dim(navec))) navec else navec[, 1]
 		nas <- seq(nas)[nas]
-		ats$NAs <- nas
+		if(length(nas))ats$NAs <- nas else ats$NAs=NULL
 	}
 	attributes(y) <- c(attributes(y), ats)
 	oldClass(y) <- cl
diff --git a/man/gam.Rd b/man/gam.Rd
index adb4474..b4171f9 100644
--- a/man/gam.Rd
+++ b/man/gam.Rd
@@ -17,13 +17,13 @@
   and smoothing splines.
   }
 \usage{
-gam(formula, family = gaussian, data, weights, subset, na.action, 
+gam(formula, family = gaussian, data, weights, subset, na.action,
        start, etastart, mustart, control = gam.control(\ldots),
 model=TRUE, method, x=FALSE, y=TRUE, \dots)
 
-gam.fit(x, y, smooth.frame, weights = rep(1,nobs), start = NULL, 
-    etastart = NULL, mustart = NULL, offset = rep(0, nobs), family = gaussian(), 
-    control = gam.control()) 
+gam.fit(x, y, smooth.frame, weights = rep(1,nobs), start = NULL,
+    etastart = NULL, mustart = NULL, offset = rep(0, nobs), family = gaussian(),
+    control = gam.control())
 }
 \arguments{
 
@@ -42,7 +42,7 @@ errors; they will simply produce the usual parametric interaction.}
     naming a family function, a family function or the result of a call
     to a family function.  (See \code{\link{family}} for details of
     family functions.)}
-  
+
   \item{data}{an optional data frame containing the variables
     in the model.  If not found in \code{data}, the variables are taken
     from \code{environment(formula)}, typically the environment from
@@ -124,7 +124,7 @@ methods. See the documentation for these methods for further information.
 In addition, the object \code{gam.wlist} (currently set to
 \code{c("s","lo")}) lists the smoothers for which efficient backfitters
 are provided. These are invoked if all the smoothing methods are of one
-kind (either all \code{"lo"} or all \code{"s"}). 
+kind (either all \code{"lo"} or all \code{"s"}).
 }
 \value{
 \code{gam} returns an object of class \code{gam}, which inherits from
@@ -143,8 +143,8 @@ that have methods for \code{gam} objects are \code{step} and
 The following components must be included in a legitimate `gam' object.
 The residuals, fitted values,  coefficients and effects should be extracted
 by the generic functions of the same name, rather than
-by the \code{"$"} operator. 
-The \code{family} function returns the entire family object used in the fitting, and \code{deviance} can be used to extract the deviance of the fit. 
+by the \code{"$"} operator.
+The \code{family} function returns the entire family object used in the fitting, and \code{deviance} can be used to extract the deviance of the fit.
 
 \item{coefficients}{
 the coefficients of the parametric part of the \code{additive.predictors}, which multiply  the
@@ -165,7 +165,7 @@ the fitted mean values, obtained by transforming  the component \code{additive.p
 }
 \item{smooth, nl.df, nl.chisq, var}{
 these four characterize the nonparametric aspect of the fit.
-\code{smooth} is a matrix of smooth terms, with a column corresponding to each smooth term in the model; if no smooth terms are in the \code{gam} model, all these components will be missing. 
+\code{smooth} is a matrix of smooth terms, with a column corresponding to each smooth term in the model; if no smooth terms are in the \code{gam} model, all these components will be missing.
 Each column corresponds to the strictly  nonparametric part of the term, while the parametric part is obtained from the model matrix.
 \code{nl.df} is a vector giving the approximate degrees of freedom for each column of \code{smooth}. For smoothing splines specified by \code{s(x)}, the approximate \code{df} will be the trace of the implicit smoother matrix minus 2.
 \code{nl.chisq} is a vector containing a type of score test for the removal of each of the columns of \code{smooth}.
@@ -175,7 +175,7 @@ Each column corresponds to the strictly  nonparametric part of the term, while t
   corresponding to the smooth terms, and has the ingredients needed for
   making predictions from a \code{gam} object}
 \item{residuals}{
-the  residuals from the final weighted additive fit; also known as 
+the  residuals from the final weighted additive fit; also known as
 residuals, these are typically not interpretable without rescaling by the weights.
 }
 \item{deviance}{
@@ -187,8 +187,8 @@ the residual sum of squares. Where sensible, the constant is chosen so that a
     \code{deviance}. The null model will include the offset, and an
     intercept if there is one in the model}
 \item{iter}{
-the number of local scoring 
-iterations used to compute the estimates. 
+the number of local scoring
+iterations used to compute the estimates.
 }
 \item{family}{
 a three-element character vector giving the name of the family, the link, and the variance function; mainly for printing purposes.
@@ -215,7 +215,7 @@ others involving the numerical fit.  See \code{lm.object}.
   "Generalized Additive Models" chapter (Hastie, 1992) in Chambers and
   Hastie (1992), and the philosophy in Hastie and Tibshirani (1991).
   This version of \code{gam} is adapted from the S
-  version to match the \code{glm} and \code{lm} functions in R. 
+  version to match the \code{glm} and \code{lm} functions in R.
 
   Note that this version of \code{gam} is different from the function
 with
diff --git a/man/gam.exact.Rd b/man/gam.exact.Rd
index f127e84..e7aeec8 100644
--- a/man/gam.exact.Rd
+++ b/man/gam.exact.Rd
@@ -12,7 +12,7 @@ gam.exact(gam.obj)
 }
 \details{
  Only standard errors for the linear terms are produced.
-There is a print method for the gamex class. 
+There is a print method for the gamex class.
 }
 \value{
  A list (of class gamex) containing a table of coefficients and a variance
@@ -24,9 +24,8 @@ There is a print method for the gamex class.
 	   \url{http://www-stat.stanford.edu/~hastie/Papers/dominiciR2.pdf}
 	 }
 \author{Aidan McDermott, Department of Biostatistics, Johns
-	   Hopkins University. See \url{http://www.ihapss.jhsph.edu/software/gam.exact/gam.exact.htm}
-	   Modified by Trevor Hastie for R}
-	 
+	   Hopkins University. Modified by Trevor Hastie for R}
+
 \examples{
 set.seed(31)
 n     <- 200
diff --git a/src/Makevars b/src/Makevars
index cb6d3f0..480af05 100644
--- a/src/Makevars
+++ b/src/Makevars
@@ -1,2 +1,3 @@
 PKG_LIBS = $(BLAS_LIBS) $(FLIBS)
 
+
diff --git a/src/loessc.c b/src/loessc.c
index b956c95..28f7c44 100644
--- a/src/loessc.c
+++ b/src/loessc.c
@@ -648,7 +648,7 @@ void F77_SUB(ehg182)(int *i)
 
 {
 
-    char *msg, msg2[50];
+    char *msg, msg2[100];
 
 #define MSG(_m_)	msg = _m_ ; break ;
 

-- 
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/debian-science/packages/r-cran-gam.git



More information about the debian-science-commits mailing list