Mercurial > octave
comparison scripts/general/interpn.m @ 31551:fd29c7a50a78 stable
maint: use commas, semicolons consistently with Octave conventions.
* makeValidName.m: Remove %!test and move BIST %!asserts to column 1.
* base64decode.m, base64encode.m, which.m, logm.m, uniquetol.m, perms.m:
Delete semicolon (';') at end of %!assert BIST.
* lin2mu.m, interp2.m, interpn.m, lsqnonneg.m, pqpnonneg.m, uniquetol.m,
betainc.m, normalize.m: Add semicolon (';') to end of assert statement within
%!test BIST.
* __memoize__.m, tar_is_bsd.m, publish.m: Add semicolon (';') to line with
keyword "persistent".
* stft.m: Use comma (',') after "case" keyword when code immediately follows.
* gallery.m: Align commas used in case statements in massive switch block.
Remove unnecessary parentheses around a numeric case argument.
* ranks.m: Remove semicolon (';') from case statemnt argument.
author | Rik <rik@octave.org> |
---|---|
date | Sat, 26 Nov 2022 06:32:08 -0800 |
parents | 731b6a5c7c4c |
children | 597f3ee61a48 |
comparison
equal
deleted
inserted
replaced
31549:ed7b17c7ddf3 | 31551:fd29c7a50a78 |
---|---|
365 %! v = rand (4, 3, 5) + 1i * rand (4, 3, 5); | 365 %! v = rand (4, 3, 5) + 1i * rand (4, 3, 5); |
366 %! for method = {"nearest", "linear", "spline"} | 366 %! for method = {"nearest", "linear", "spline"} |
367 %! vi_complex = interpn (v, yi, xi, zi, method{1}); | 367 %! vi_complex = interpn (v, yi, xi, zi, method{1}); |
368 %! vi_real = interpn (real (v), yi, xi, zi, method{1}); | 368 %! vi_real = interpn (real (v), yi, xi, zi, method{1}); |
369 %! vi_imag = interpn (imag (v), yi, xi, zi, method{1}); | 369 %! vi_imag = interpn (imag (v), yi, xi, zi, method{1}); |
370 %! assert (real (vi_complex), vi_real, 2*eps) | 370 %! assert (real (vi_complex), vi_real, 2*eps); |
371 %! assert (imag (vi_complex), vi_imag, 2*eps) | 371 %! assert (imag (vi_complex), vi_imag, 2*eps); |
372 %! endfor | 372 %! endfor |
373 | 373 |
374 ## Test input validation | 374 ## Test input validation |
375 %!error <Invalid call> interpn () | 375 %!error <Invalid call> interpn () |
376 %!error <Invalid call> interpn ("foobar") | 376 %!error <Invalid call> interpn ("foobar") |