Mercurial > hg > octave-nkf
diff scripts/deprecated/autocor.m @ 11165:5962c1cfdbcb
Deprecate autocor and autocov functions.
author | Rik <octave@nomad.inbox5.com> |
---|---|
date | Thu, 28 Oct 2010 18:18:19 -0700 |
parents | scripts/signal/autocor.m@a1dbe9d80eee |
children | fd0a3ac60b0e |
line wrap: on
line diff
copy from scripts/signal/autocor.m copy to scripts/deprecated/autocor.m --- a/scripts/signal/autocor.m +++ b/scripts/deprecated/autocor.m @@ -23,13 +23,25 @@ ## If @var{h} is omitted, all autocorrelations are computed. ## If @var{x} is a matrix, the autocorrelations of each column are ## computed. +## The particular algorithm used is from the field of statistics and +## differs from the definition used in signal processing. ## @end deftypefn ## Author: FL <Friedrich.Leisch@ci.tuwien.ac.at> ## Description: Compute autocorrelations +## Deprecated in version 3.4 + function retval = autocor (X, h) + persistent warned = false; + if (! warned) + warned = true; + warning ("Octave:deprecated-function", + "autocor is obsolete and will be removed from a future version of Octave; See the Octave-Forge signal package and the function xcor for a replacement"); + endif + + if (nargin == 1) retval = autocov (X); elseif (nargin == 2)