summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSuraj Yerramilli2015-08-22 15:01:16 +0530
committerSuraj Yerramilli2015-08-22 15:01:16 +0530
commit8be3e84001ee8320bb8eb256dce2171428d74a7e (patch)
treee02584206919856b913973e7a5b4f8eb82d5a617
parent558f3da63f981823a211c9354406db90a3db4c6c (diff)
downloadSysID-R-code-8be3e84001ee8320bb8eb256dce2171428d74a7e.tar.gz
SysID-R-code-8be3e84001ee8320bb8eb256dce2171428d74a7e.tar.bz2
SysID-R-code-8be3e84001ee8320bb8eb256dce2171428d74a7e.zip
Minor touches to the plot function
-rw-r--r--R/idframe.R5
1 files changed, 3 insertions, 2 deletions
diff --git a/R/idframe.R b/R/idframe.R
index 19530fc..9b79245 100644
--- a/R/idframe.R
+++ b/R/idframe.R
@@ -58,12 +58,13 @@ idframe <- function(output=NULL,input=NULL,Ts = 1,start=0,end=NULL,
plot.idframe <- function(x,par=list(mar=c(3,4,2,2)),
col="steelblue",...){
require(tfplot)
- if(nOutputSeries(x)==0){
+ if(nInputSeries(x)==0){
data <- outputData(x)
} else if(nOutputSeries(x)==0){
- data <- outputData(x)
+ data <- inputData(x)
} else{
data <- cbind(outputData(x),inputData(x))
+ colnames(data) <- c(outputNames(x),inputNames(x))
}
tfplot(data,Xaxis=NULL,par=par,col=col,...)
}