From 3b3d6dfc88c4b8b6475147a3afb5258a5fc82fa5 Mon Sep 17 00:00:00 2001 From: ranke Date: Tue, 23 May 2006 15:24:58 +0000 Subject: First version published on my website. git-svn-id: http://kriemhild.uft.uni-bremen.de/svn/chemCal@14 5fad18fb-23f0-0310-ab10-e59a3bee62b4 --- R/calplot.R | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) (limited to 'R/calplot.R') diff --git a/R/calplot.R b/R/calplot.R index 753d333..0cc6120 100644 --- a/R/calplot.R +++ b/R/calplot.R @@ -24,11 +24,10 @@ calplot.lm <- function(object, if (length(object$weights) > 0) { stop(paste( - "\nConfidence and prediction intervals for weighted linear models require", - "weights for the x values from which the predictions are to be generated.", - "This is not supported by the internally used predict.lm method.", - sep = "\n" - )) + "\nConfidence and prediction intervals for weighted linear models require", + "weights for the x values from which the predictions are to be generated.", + "This is not supported by the internally used predict.lm method.", + sep = "\n")) } if (alpha <= 0 | alpha >= 1) @@ -40,8 +39,9 @@ calplot.lm <- function(object, x <- m$model[[2]] if (xlim[1] == "auto") xlim[1] <- 0 if (xlim[2] == "auto") xlim[2] <- max(x) + xlim <- as.numeric(xlim) newdata <- list( - x = seq(from = xlim[1], to = xlim[2], length=250)) + x = seq(from = xlim[[1]], to = xlim[[2]], length=250)) names(newdata) <- names(m$model)[[2]] if (is.null(varfunc)) { varfunc <- if (length(m$weights)) { -- cgit v1.2.1