summaryrefslogtreecommitdiff
path: root/R/nonparam.R
diff options
context:
space:
mode:
authorSuraj Yerramilli2016-02-24 14:01:04 +0530
committerSuraj Yerramilli2016-02-24 14:01:04 +0530
commit55b5704c4042761d1efc6f129b3068176fd50b04 (patch)
tree7bc68b7f5978c75dd281504889628ce3854d94ff /R/nonparam.R
parentd75f12453738d230b27422fa135425d5a99159d0 (diff)
downloadSysID-R-code-55b5704c4042761d1efc6f129b3068176fd50b04.tar.gz
SysID-R-code-55b5704c4042761d1efc6f129b3068176fd50b04.tar.bz2
SysID-R-code-55b5704c4042761d1efc6f129b3068176fd50b04.zip
adjusting limits in impulse response plot
Diffstat (limited to 'R/nonparam.R')
-rw-r--r--R/nonparam.R3
1 files changed, 2 insertions, 1 deletions
diff --git a/R/nonparam.R b/R/nonparam.R
index 932b97d..487dbcd 100644
--- a/R/nonparam.R
+++ b/R/nonparam.R
@@ -94,7 +94,8 @@ plot.impulseest <- function(model,sig=0.975){
impulseplot <- function(model,sig){
lim <- model$se*qnorm(sig)
- ylim <- c(min(coef(model)),max(coef(model)))
+ max <- max(abs(coef(model)))
+ ylim <- c(-max,max)
title <- paste("Impulse Response \n From",model$x,"to",model$y)
plot(model$lags,coef(model),type="h",xlab="Lag",ylab= "IR Coefficient",