changeset 70:c31551201ddc octave-forge

Return a vector of lags rather than a range
author pkienzle
date Fri, 07 Dec 2001 15:52:37 +0000
parents 920107031030
children 8d8c6ca56a1e
files main/signal/xcorr.m
diffstat 1 files changed, 3 insertions(+), 1 deletions(-) [+]
line wrap: on
line diff
--- a/main/signal/xcorr.m	Fri Dec 07 15:48:01 2001 +0000
+++ b/main/signal/xcorr.m	Fri Dec 07 15:52:37 2001 +0000
@@ -50,6 +50,8 @@
 ##     - remove all but one loop
 ## 2001-10-30 Paul Kienzle <pkienzle@users.sf.net>
 ##     - fix arg parsing for 3 args
+## 2001-12-05 Paul Kienzle <pkienzle@users.sf.net>
+##     - return lags as vector rather than range
 
 function [R, lags] = xcorr (X, Y, maxlag, scale)
   
@@ -160,7 +162,7 @@
   
   ## return the lag indices if desired
   if nargout == 2
-    lags = -maxlag:maxlag;
+    lags = [-maxlag:maxlag];
   endif
 
 endfunction