Mercurial > forge
changeset 297:d9723a1203b2 octave-forge
automatic mode is fully automatic now
author | schloegl |
---|---|
date | Mon, 15 Apr 2002 18:59:07 +0000 |
parents | b3208bf8490a |
children | c2142b4e6585 |
files | extra/tsa/invest1.m |
diffstat | 1 files changed, 10 insertions(+), 6 deletions(-) [+] |
line wrap: on
line diff
--- a/extra/tsa/invest1.m Mon Apr 15 03:54:33 2002 +0000 +++ b/extra/tsa/invest1.m Mon Apr 15 18:59:07 2002 +0000 @@ -1,5 +1,5 @@ function [AutoCov,AutoCorr,ARPMX,E,C,s]=invest1(Y,Pmax,D); -% First Investigation of a signal (time series) - interactive +% First Investigation of a signal (time series) - interactive % [AutoCov,AutoCorr,ARPMX,E,CRITERIA,MOPS]=invest1(Y,Pmax,show); % % Y time series @@ -39,8 +39,8 @@ % optPHI order where PHI is minimal % optRC2 max reflection coefficient larger than std-error -% Version 2.84 -% 21.02.2002 +% Version 2.90 +% 15.04.2002 % Copyright (c) 1998-2002 by Alois Schloegl % a.schloegl@ieee.org @@ -82,9 +82,13 @@ X = 0:Dmax; H = zeros(1,Dmax+1); for k=1:length(x), H(find(X==x(k)))=h(k); end; bar(X,H); drawnow; - - oD=input('Which order should be used for differentiating [default=0] ?: '); - if oD>0 + + if nargin>2 + oD=0; + else + oD=input('Which order should be used for differentiating [default=0] ?: '); + end; + if oD>0 Y=diff(Y,oD,2); end; end;