diff scripts/signal/movfun.m @ 30893:e1788b1a315f

maint: Use "fcn" as preferred abbreviation for "function" in m-files. * accumarray.m, accumdim.m, quadl.m, quadv.m, randi.m, structfun.m, __is_function__.m, uigetfile.m, uimenu.m, uiputfile.m, doc_cache_create.m, colorspace_conversion_input_check.m, imageIO.m, argnames.m, vectorize.m, vectorize.m, normest1.m, inputname.m, nthargout.m, display_info_file.m, decic.m, ode15i.m, ode15s.m, ode23.m, ode23s.m, ode45.m, odeset.m, check_default_input.m, integrate_adaptive.m, ode_event_handler.m, runge_kutta_23.m, runge_kutta_23s.m, runge_kutta_45_dorpri.m, runge_kutta_interpolate.m, starting_stepsize.m, __all_opts__.m, fminbnd.m, fminsearch.m, fminunc.m, fsolve.m, fzero.m, sqp.m, fplot.m, plotyy.m, __bar__.m, __ezplot__.m, flat_entry.html, profexport.m, movfun.m, bicg.m, bicgstab.m, cgs.m, eigs.m, gmres.m, pcg.m, __alltohandles__.m, __sprand__.m, qmr.m, tfqmr.m, dump_demos.m: Replace "func", "fun", "fn" in documentation and variable names with "fcn".
author Rik <rik@octave.org>
date Mon, 04 Apr 2022 18:14:56 -0700
parents 796f54d4ddbf
children 597f3ee61a48
line wrap: on
line diff
--- a/scripts/signal/movfun.m	Mon Apr 04 11:22:26 2022 -0700
+++ b/scripts/signal/movfun.m	Mon Apr 04 18:14:56 2022 -0700
@@ -227,29 +227,29 @@
 
   ## Obtain function for boundary conditions
   if (isnumeric (bc))
-    bcfunc = @replaceval_bc;
-    bcfunc (true, bc);  # initialize replaceval function with value
+    bcfcn = @replaceval_bc;
+    bcfcn (true, bc);  # initialize replaceval function with value
   else
     switch (tolower (bc))
       case "shrink"
-        bcfunc = @shrink_bc;
+        bcfcn = @shrink_bc;
 
       case "discard"
-        bcfunc = [];
+        bcfcn = [];
         C -= length (Cpre);
         Cpre = Cpos = [];
         N = length (C);
         szx(dperm(1)) = N;
 
       case "fill"
-        bcfunc = @replaceval_bc;
-        bcfunc (true, NaN);
+        bcfcn = @replaceval_bc;
+        bcfcn (true, NaN);
 
       case "same"
-        bcfunc = @same_bc;
+        bcfcn = @same_bc;
 
       case "periodic"
-        bcfunc = @periodic_bc;
+        bcfcn = @periodic_bc;
 
     endswitch
   endif
@@ -279,7 +279,7 @@
   ## FIXME: Is it faster with cellfun?  Don't think so, but needs testing.
   y = zeros (N, ncols, soutdim);
   parfor i = 1:ncols
-    y(:,i,:) = movfun_oncol (fcn_, x(:,i), wlen, bcfunc,
+    y(:,i,:) = movfun_oncol (fcn_, x(:,i), wlen, bcfcn,
                              slc, C, Cpre, Cpos, win, soutdim);
   endparfor
 
@@ -290,7 +290,7 @@
 
 endfunction
 
-function y = movfun_oncol (fcn, x, wlen, bcfunc, slcidx, C, Cpre, Cpos, win, odim)
+function y = movfun_oncol (fcn, x, wlen, bcfcn, slcidx, C, Cpre, Cpos, win, odim)
 
   N = length (Cpre) + length (C) + length (Cpos);
   y = NA (N, odim);
@@ -300,10 +300,10 @@
 
   ## Process boundaries
   if (! isempty (Cpre))
-    y(Cpre,:) = bcfunc (fcn, x, Cpre, win, wlen, odim);
+    y(Cpre,:) = bcfcn (fcn, x, Cpre, win, wlen, odim);
   endif
   if (! isempty (Cpos))
-    y(Cpos,:) = bcfunc (fcn, x, Cpos, win, wlen, odim);
+    y(Cpos,:) = bcfcn (fcn, x, Cpos, win, wlen, odim);
   endif
 
 endfunction