Hello, Le 20/09/2012 00:05, Lester Anderson a écrit :
function w=tukeywin(L,r= 1/2) if (nargin < 1 || nargin > 2) ------ Not sure how to replace this bit (variable not defined)
nargin => argn(2)
.../... // generate window switch r --------- think this should be select ?
Right
.../... case 1, // Hanning window w = hanning (L);
window('hn',L)
otherwise ------------- else
Yes
// cosine-tapered window t = linspace(0,1,L)(1:end/2)';
replace end with $ : (1:$/2)';
w = (1 + cos(pi*(2*t/r-1)))/2;
pi => %pi
w(floor(r*(L-1)/2)+2:end) = 1; w = [w; ones(mod(L,2)); flipud(w)];
mod => modulo flipud(w) => flipdim(w,1)
endswitch ------------------------------------ end ?
Yes
_______________________________________________ users mailing list users@lists.scilab.org http://lists.scilab.org/mailman/listinfo/users