diff options
author | Suraj Yerramilli | 2015-12-30 16:04:58 +0530 |
---|---|---|
committer | Suraj Yerramilli | 2015-12-30 16:04:58 +0530 |
commit | 8d657cc8489fe4360a129cb931b343c28a19033d (patch) | |
tree | f2f6acd970930501d9aacfc7d7a68519db1a3098 | |
parent | 78ef826e33820773cefd4fef6c29792e393ec675 (diff) | |
download | SysID-R-code-8d657cc8489fe4360a129cb931b343c28a19033d.tar.gz SysID-R-code-8d657cc8489fe4360a129cb931b343c28a19033d.tar.bz2 SysID-R-code-8d657cc8489fe4360a129cb931b343c28a19033d.zip |
Corrected Error in plot function
-rw-r--r-- | R/estpoly.R | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/R/estpoly.R b/R/estpoly.R index 4508ff5..7d27cf8 100644 --- a/R/estpoly.R +++ b/R/estpoly.R @@ -74,8 +74,8 @@ plot.estpoly <- function(model,newdata=NULL){ require(ggplot2) if(is.null(newdata)){ - ypred <- fitted(model) - yact <- fitted(model) + resid(model) + ypred <- ts(fitted(model),names="Predicted") + yact <- ts(fitted(model) + resid(model),names="Actual") time <- time(model$input) titstr <- "Predictions of Model on Training Set" } else{ |