annotate scripts/general/prepad.m @ 20158:7503499a252b stable

doc: Update docstrings to have one sentence summary as first line. Update scripts in audio, elfun, general, geometry, and image directories. * scripts/audio/@audioplayer/__get_properties__.m, scripts/audio/@audioplayer/audioplayer.m, scripts/audio/@audioplayer/get.m, scripts/audio/@audioplayer/isplaying.m, scripts/audio/@audioplayer/play.m, scripts/audio/@audioplayer/playblocking.m, scripts/audio/@audioplayer/set.m, scripts/audio/@audioplayer/subsasgn.m, scripts/audio/@audioplayer/subsref.m, scripts/audio/@audiorecorder/audiorecorder.m, scripts/audio/@audiorecorder/get.m, scripts/audio/@audiorecorder/getaudiodata.m, scripts/audio/@audiorecorder/getplayer.m, scripts/audio/@audiorecorder/isrecording.m, scripts/audio/@audiorecorder/play.m, scripts/audio/@audiorecorder/record.m, scripts/audio/@audiorecorder/recordblocking.m, scripts/audio/@audiorecorder/set.m, scripts/audio/@audiorecorder/stop.m, scripts/audio/@audiorecorder/subsasgn.m, scripts/audio/@audiorecorder/subsref.m, scripts/audio/lin2mu.m, scripts/audio/mu2lin.m, scripts/audio/record.m, scripts/audio/sound.m, scripts/audio/soundsc.m, scripts/audio/wavread.m, scripts/audio/wavwrite.m, scripts/elfun/cosd.m, scripts/elfun/sind.m, scripts/elfun/tand.m, scripts/general/accumarray.m, scripts/general/accumdim.m, scripts/general/bitcmp.m, scripts/general/bitget.m, scripts/general/bitset.m, scripts/general/blkdiag.m, scripts/general/cart2pol.m, scripts/general/cart2sph.m, scripts/general/cell2mat.m, scripts/general/celldisp.m, scripts/general/chop.m, scripts/general/circshift.m, scripts/general/common_size.m, scripts/general/cplxpair.m, scripts/general/cumtrapz.m, scripts/general/dblquad.m, scripts/general/deal.m, scripts/general/del2.m, scripts/general/display.m, scripts/general/divergence.m, scripts/general/fieldnames.m, scripts/general/flip.m, scripts/general/flipdim.m, scripts/general/fliplr.m, scripts/general/flipud.m, scripts/general/gradient.m, scripts/general/interp3.m, scripts/general/interpft.m, scripts/general/interpn.m, scripts/general/loadobj.m, scripts/general/logspace.m, scripts/general/methods.m, scripts/general/nargchk.m, scripts/general/narginchk.m, scripts/general/nargoutchk.m, scripts/general/nextpow2.m, scripts/general/nthargout.m, scripts/general/num2str.m, scripts/general/pol2cart.m, scripts/general/polyarea.m, scripts/general/postpad.m, scripts/general/prepad.m, scripts/general/profile.m, scripts/general/quadgk.m, scripts/general/quadl.m, scripts/general/quadv.m, scripts/general/randi.m, scripts/general/rat.m, scripts/general/repmat.m, scripts/general/rot90.m, scripts/general/rotdim.m, scripts/general/saveobj.m, scripts/general/shift.m, scripts/general/shiftdim.m, scripts/general/sortrows.m, scripts/general/sph2cart.m, scripts/general/structfun.m, scripts/general/subsindex.m, scripts/general/trapz.m, scripts/general/triplequad.m, scripts/geometry/delaunayn.m, scripts/geometry/dsearch.m, scripts/geometry/dsearchn.m, scripts/geometry/griddata.m, scripts/geometry/griddata3.m, scripts/geometry/griddatan.m, scripts/geometry/inpolygon.m, scripts/geometry/rectint.m, scripts/geometry/tsearchn.m, scripts/geometry/voronoi.m, scripts/geometry/voronoin.m, scripts/help/__unimplemented__.m, scripts/help/doc.m, scripts/help/doc_cache_create.m, scripts/help/get_first_help_sentence.m, scripts/help/help.m, scripts/help/lookfor.m, scripts/help/print_usage.m, scripts/help/type.m, scripts/help/which.m, scripts/image/autumn.m, scripts/image/bone.m, scripts/image/brighten.m, scripts/image/cmpermute.m, scripts/image/colorcube.m, scripts/image/contrast.m, scripts/image/cool.m, scripts/image/copper.m, scripts/image/cubehelix.m, scripts/image/flag.m, scripts/image/gmap40.m, scripts/image/gray.m, scripts/image/gray2ind.m, scripts/image/hot.m, scripts/image/hsv.m, scripts/image/image.m, scripts/image/imagesc.m, scripts/image/imfinfo.m, scripts/image/imformats.m, scripts/image/imread.m, scripts/image/imshow.m, scripts/image/imwrite.m, scripts/image/iscolormap.m, scripts/image/jet.m, scripts/image/lines.m, scripts/image/ntsc2rgb.m, scripts/image/ocean.m, scripts/image/pink.m, scripts/image/prism.m, scripts/image/rainbow.m, scripts/image/rgb2ntsc.m, scripts/image/spinmap.m, scripts/image/spring.m, scripts/image/summer.m, scripts/image/white.m, scripts/image/winter.m: Update docstrings to have one sentence summary as first line. Re-structure to have line lengths <= 80 chars.
author Rik <rik@octave.org>
date Sun, 03 May 2015 09:36:20 -0700
parents 9fc020886ae9
children
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
19697
4197fc428c7d maint: Update copyright notices for 2015.
John W. Eaton <jwe@octave.org>
parents: 19654
diff changeset
1 ## Copyright (C) 1994-2015 John W. Eaton
2313
5ca126254d15 [project @ 1996-07-11 21:25:22 by jwe]
jwe
parents: 2311
diff changeset
2 ##
5ca126254d15 [project @ 1996-07-11 21:25:22 by jwe]
jwe
parents: 2311
diff changeset
3 ## This file is part of Octave.
5ca126254d15 [project @ 1996-07-11 21:25:22 by jwe]
jwe
parents: 2311
diff changeset
4 ##
5ca126254d15 [project @ 1996-07-11 21:25:22 by jwe]
jwe
parents: 2311
diff changeset
5 ## Octave is free software; you can redistribute it and/or modify it
5ca126254d15 [project @ 1996-07-11 21:25:22 by jwe]
jwe
parents: 2311
diff changeset
6 ## under the terms of the GNU General Public License as published by
7016
93c65f2a5668 [project @ 2007-10-12 06:40:56 by jwe]
jwe
parents: 6046
diff changeset
7 ## the Free Software Foundation; either version 3 of the License, or (at
93c65f2a5668 [project @ 2007-10-12 06:40:56 by jwe]
jwe
parents: 6046
diff changeset
8 ## your option) any later version.
2313
5ca126254d15 [project @ 1996-07-11 21:25:22 by jwe]
jwe
parents: 2311
diff changeset
9 ##
5ca126254d15 [project @ 1996-07-11 21:25:22 by jwe]
jwe
parents: 2311
diff changeset
10 ## Octave is distributed in the hope that it will be useful, but
5ca126254d15 [project @ 1996-07-11 21:25:22 by jwe]
jwe
parents: 2311
diff changeset
11 ## WITHOUT ANY WARRANTY; without even the implied warranty of
5ca126254d15 [project @ 1996-07-11 21:25:22 by jwe]
jwe
parents: 2311
diff changeset
12 ## MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
5ca126254d15 [project @ 1996-07-11 21:25:22 by jwe]
jwe
parents: 2311
diff changeset
13 ## General Public License for more details.
5ca126254d15 [project @ 1996-07-11 21:25:22 by jwe]
jwe
parents: 2311
diff changeset
14 ##
5ca126254d15 [project @ 1996-07-11 21:25:22 by jwe]
jwe
parents: 2311
diff changeset
15 ## You should have received a copy of the GNU General Public License
7016
93c65f2a5668 [project @ 2007-10-12 06:40:56 by jwe]
jwe
parents: 6046
diff changeset
16 ## along with Octave; see the file COPYING. If not, see
93c65f2a5668 [project @ 2007-10-12 06:40:56 by jwe]
jwe
parents: 6046
diff changeset
17 ## <http://www.gnu.org/licenses/>.
2303
5cffc4b8de57 [project @ 1996-06-24 09:15:24 by jwe]
jwe
parents: 1337
diff changeset
18
3428
5b77cf82393c [project @ 2000-01-14 02:54:53 by jwe]
jwe
parents: 3202
diff changeset
19 ## -*- texinfo -*-
11539
6bac61388876 Add undocumented postpad function to documentation.
Rik <octave@nomad.inbox5.com>
parents: 11523
diff changeset
20 ## @deftypefn {Function File} {} prepad (@var{x}, @var{l})
6bac61388876 Add undocumented postpad function to documentation.
Rik <octave@nomad.inbox5.com>
parents: 11523
diff changeset
21 ## @deftypefnx {Function File} {} prepad (@var{x}, @var{l}, @var{c})
8545
faccdb98d953 postpad.m, prepad.m: doc fix
John W. Eaton <jwe@octave.org>
parents: 8436
diff changeset
22 ## @deftypefnx {Function File} {} prepad (@var{x}, @var{l}, @var{c}, @var{dim})
12639
4d777e05d47c doc: Review and update documentation for "Matrix Manipulation" chapter.
Rik <octave@nomad.inbox5.com>
parents: 11539
diff changeset
23 ## Prepend the scalar value @var{c} to the vector @var{x} until it is of length
4d777e05d47c doc: Review and update documentation for "Matrix Manipulation" chapter.
Rik <octave@nomad.inbox5.com>
parents: 11539
diff changeset
24 ## @var{l}. If @var{c} is not given, a value of 0 is used.
2311
2b5788792cad [project @ 1996-07-11 20:18:38 by jwe]
jwe
parents: 2303
diff changeset
25 ##
20158
7503499a252b doc: Update docstrings to have one sentence summary as first line.
Rik <rik@octave.org>
parents: 19833
diff changeset
26 ## If @code{length (@var{x}) > @var{l}}, elements from the beginning of @var{x}
7503499a252b doc: Update docstrings to have one sentence summary as first line.
Rik <rik@octave.org>
parents: 19833
diff changeset
27 ## are removed until a vector of length @var{l} is obtained.
3652
25e84fcef38a [project @ 2000-03-31 08:50:48 by jwe]
jwe
parents: 3500
diff changeset
28 ##
25e84fcef38a [project @ 2000-03-31 08:50:48 by jwe]
jwe
parents: 3500
diff changeset
29 ## If @var{x} is a matrix, elements are prepended or removed from each row.
4870
2cbc6f37b0c2 [project @ 2004-04-21 17:30:51 by jwe]
jwe
parents: 4862
diff changeset
30 ##
20158
7503499a252b doc: Update docstrings to have one sentence summary as first line.
Rik <rik@octave.org>
parents: 19833
diff changeset
31 ## If the optional argument @var{dim} is given, operate along this dimension.
18513
d28c4c4547ef Allow postpad and prepad to expand singleton dimensions (bug #41633)
Mike Miller <mtmiller@ieee.org>
parents: 17744
diff changeset
32 ##
20158
7503499a252b doc: Update docstrings to have one sentence summary as first line.
Rik <rik@octave.org>
parents: 19833
diff changeset
33 ## If @var{dim} is larger than the dimensions of @var{x}, the result will have
7503499a252b doc: Update docstrings to have one sentence summary as first line.
Rik <rik@octave.org>
parents: 19833
diff changeset
34 ## @var{dim} dimensions.
11539
6bac61388876 Add undocumented postpad function to documentation.
Rik <octave@nomad.inbox5.com>
parents: 11523
diff changeset
35 ## @seealso{postpad, cat, resize}
3428
5b77cf82393c [project @ 2000-01-14 02:54:53 by jwe]
jwe
parents: 3202
diff changeset
36 ## @end deftypefn
5b77cf82393c [project @ 2000-01-14 02:54:53 by jwe]
jwe
parents: 3202
diff changeset
37
5b77cf82393c [project @ 2000-01-14 02:54:53 by jwe]
jwe
parents: 3202
diff changeset
38 ## Author: Tony Richardson <arichard@stark.cc.oh.us>
5b77cf82393c [project @ 2000-01-14 02:54:53 by jwe]
jwe
parents: 3202
diff changeset
39 ## Created: June 1994
1337
52a3f38cbfeb [project @ 1995-08-25 02:00:18 by jwe]
jwe
parents: 904
diff changeset
40
4862
a0997c4d1d54 [project @ 2004-04-15 21:14:43 by jwe]
jwe
parents: 4030
diff changeset
41 function y = prepad (x, l, c, dim)
a0997c4d1d54 [project @ 2004-04-15 21:14:43 by jwe]
jwe
parents: 4030
diff changeset
42
a0997c4d1d54 [project @ 2004-04-15 21:14:43 by jwe]
jwe
parents: 4030
diff changeset
43 if (nargin < 2 || nargin > 4)
6046
34f96dd5441b [project @ 2006-10-10 16:10:25 by jwe]
jwe
parents: 5459
diff changeset
44 print_usage ();
4862
a0997c4d1d54 [project @ 2004-04-15 21:14:43 by jwe]
jwe
parents: 4030
diff changeset
45 endif
a0997c4d1d54 [project @ 2004-04-15 21:14:43 by jwe]
jwe
parents: 4030
diff changeset
46
a0997c4d1d54 [project @ 2004-04-15 21:14:43 by jwe]
jwe
parents: 4030
diff changeset
47 if (nargin < 3 || isempty (c))
a0997c4d1d54 [project @ 2004-04-15 21:14:43 by jwe]
jwe
parents: 4030
diff changeset
48 c = 0;
a0997c4d1d54 [project @ 2004-04-15 21:14:43 by jwe]
jwe
parents: 4030
diff changeset
49 else
a0997c4d1d54 [project @ 2004-04-15 21:14:43 by jwe]
jwe
parents: 4030
diff changeset
50 if (! isscalar (c))
14406
98cf8aa9f8ba prepad.m: Improve input validation messages and tests.
Rik <octave@nomad.inbox5.com>
parents: 14363
diff changeset
51 error ("prepad: pad value C must be empty or a scalar");
4862
a0997c4d1d54 [project @ 2004-04-15 21:14:43 by jwe]
jwe
parents: 4030
diff changeset
52 endif
a0997c4d1d54 [project @ 2004-04-15 21:14:43 by jwe]
jwe
parents: 4030
diff changeset
53 endif
559
4e826edfbc56 [project @ 1994-07-25 22:18:28 by jwe]
jwe
parents:
diff changeset
54
4862
a0997c4d1d54 [project @ 2004-04-15 21:14:43 by jwe]
jwe
parents: 4030
diff changeset
55 nd = ndims (x);
a0997c4d1d54 [project @ 2004-04-15 21:14:43 by jwe]
jwe
parents: 4030
diff changeset
56 sz = size (x);
a0997c4d1d54 [project @ 2004-04-15 21:14:43 by jwe]
jwe
parents: 4030
diff changeset
57 if (nargin < 4)
12674
9493880928c8 Use common idiom in m-files for finding first non-singleton dimension.
Rik <octave@nomad.inbox5.com>
parents: 12639
diff changeset
58 ## Find the first non-singleton dimension.
9493880928c8 Use common idiom in m-files for finding first non-singleton dimension.
Rik <octave@nomad.inbox5.com>
parents: 12639
diff changeset
59 (dim = find (sz > 1, 1)) || (dim = 1);
4862
a0997c4d1d54 [project @ 2004-04-15 21:14:43 by jwe]
jwe
parents: 4030
diff changeset
60 else
18513
d28c4c4547ef Allow postpad and prepad to expand singleton dimensions (bug #41633)
Mike Miller <mtmiller@ieee.org>
parents: 17744
diff changeset
61 if (!(isscalar (dim) && dim == fix (dim) && dim >= 1))
10690
35adf2a71f3f Use common code block to find first non-singleton dimension.
Rik <octave@nomad.inbox5.com>
parents: 10635
diff changeset
62 error ("prepad: DIM must be an integer and a valid dimension");
4862
a0997c4d1d54 [project @ 2004-04-15 21:14:43 by jwe]
jwe
parents: 4030
diff changeset
63 endif
559
4e826edfbc56 [project @ 1994-07-25 22:18:28 by jwe]
jwe
parents:
diff changeset
64 endif
4e826edfbc56 [project @ 1994-07-25 22:18:28 by jwe]
jwe
parents:
diff changeset
65
5459
ff40c78cebf0 [project @ 2005-09-20 19:18:34 by jwe]
jwe
parents: 5307
diff changeset
66 if (! isscalar (l) || l < 0)
14406
98cf8aa9f8ba prepad.m: Improve input validation messages and tests.
Rik <octave@nomad.inbox5.com>
parents: 14363
diff changeset
67 error ("prepad: length L must be a positive scalar");
559
4e826edfbc56 [project @ 1994-07-25 22:18:28 by jwe]
jwe
parents:
diff changeset
68 endif
4e826edfbc56 [project @ 1994-07-25 22:18:28 by jwe]
jwe
parents:
diff changeset
69
5459
ff40c78cebf0 [project @ 2005-09-20 19:18:34 by jwe]
jwe
parents: 5307
diff changeset
70 if (dim > nd)
ff40c78cebf0 [project @ 2005-09-20 19:18:34 by jwe]
jwe
parents: 5307
diff changeset
71 sz(nd+1:dim) = 1;
ff40c78cebf0 [project @ 2005-09-20 19:18:34 by jwe]
jwe
parents: 5307
diff changeset
72 endif
ff40c78cebf0 [project @ 2005-09-20 19:18:34 by jwe]
jwe
parents: 5307
diff changeset
73
19833
9fc020886ae9 maint: Clean up m-files to follow Octave coding conventions.
Rik <rik@octave.org>
parents: 19697
diff changeset
74 d = sz(dim);
4862
a0997c4d1d54 [project @ 2004-04-15 21:14:43 by jwe]
jwe
parents: 4030
diff changeset
75
a0997c4d1d54 [project @ 2004-04-15 21:14:43 by jwe]
jwe
parents: 4030
diff changeset
76 if (d >= l)
12676
2783fa95cab7 Use common code idiom for creating cell array for indexing ND-arrays
Rik <octave@nomad.inbox5.com>
parents: 12674
diff changeset
77 idx = repmat ({':'}, nd, 1);
7208
a730e47fda4d [project @ 2007-11-28 02:32:41 by jwe]
jwe
parents: 7017
diff changeset
78 idx{dim} = d-l+1:d;
a730e47fda4d [project @ 2007-11-28 02:32:41 by jwe]
jwe
parents: 7017
diff changeset
79 y = x(idx{:});
559
4e826edfbc56 [project @ 1994-07-25 22:18:28 by jwe]
jwe
parents:
diff changeset
80 else
19833
9fc020886ae9 maint: Clean up m-files to follow Octave coding conventions.
Rik <rik@octave.org>
parents: 19697
diff changeset
81 sz(dim) = l - d;
19654
107ec5195a47 prepad.m: Fix str-to-num warnings (bug #44162)
Mike Miller <mtmiller@ieee.org>
parents: 18857
diff changeset
82 y = cat (dim, c(ones (sz)), x);
559
4e826edfbc56 [project @ 1994-07-25 22:18:28 by jwe]
jwe
parents:
diff changeset
83 endif
4e826edfbc56 [project @ 1994-07-25 22:18:28 by jwe]
jwe
parents:
diff changeset
84
4e826edfbc56 [project @ 1994-07-25 22:18:28 by jwe]
jwe
parents:
diff changeset
85 endfunction
12795
9e7ebbaf69ff codesprint: new tests for files in scripts/general directory
John W. Eaton <jwe@octave.org>
parents: 12676
diff changeset
86
14363
f3d52523cde1 Use Octave coding conventions in all m-file %!test blocks
Rik <octave@nomad.inbox5.com>
parents: 14138
diff changeset
87
f3d52523cde1 Use Octave coding conventions in all m-file %!test blocks
Rik <octave@nomad.inbox5.com>
parents: 14138
diff changeset
88 %!assert (prepad ([1,2], 4), [0,0,1,2])
f3d52523cde1 Use Octave coding conventions in all m-file %!test blocks
Rik <octave@nomad.inbox5.com>
parents: 14138
diff changeset
89 %!assert (prepad ([1;2], 4), [0;0;1;2])
12795
9e7ebbaf69ff codesprint: new tests for files in scripts/general directory
John W. Eaton <jwe@octave.org>
parents: 12676
diff changeset
90
14363
f3d52523cde1 Use Octave coding conventions in all m-file %!test blocks
Rik <octave@nomad.inbox5.com>
parents: 14138
diff changeset
91 %!assert (prepad ([1,2], 4, 2), [2,2,1,2])
f3d52523cde1 Use Octave coding conventions in all m-file %!test blocks
Rik <octave@nomad.inbox5.com>
parents: 14138
diff changeset
92 %!assert (prepad ([1;2], 4, 2), [2;2;1;2])
12795
9e7ebbaf69ff codesprint: new tests for files in scripts/general directory
John W. Eaton <jwe@octave.org>
parents: 12676
diff changeset
93
14363
f3d52523cde1 Use Octave coding conventions in all m-file %!test blocks
Rik <octave@nomad.inbox5.com>
parents: 14138
diff changeset
94 %!assert (prepad ([1,2], 2, 2, 1), [2,2;1,2])
12795
9e7ebbaf69ff codesprint: new tests for files in scripts/general directory
John W. Eaton <jwe@octave.org>
parents: 12676
diff changeset
95
18513
d28c4c4547ef Allow postpad and prepad to expand singleton dimensions (bug #41633)
Mike Miller <mtmiller@ieee.org>
parents: 17744
diff changeset
96 %!assert (prepad ([1,2], 2, 2, 3), reshape ([2,2,1,2], 1, 2, 2))
d28c4c4547ef Allow postpad and prepad to expand singleton dimensions (bug #41633)
Mike Miller <mtmiller@ieee.org>
parents: 17744
diff changeset
97 %!assert (prepad ([1;2], 2, 2, 3), reshape ([2;2;1;2], 2, 1, 2))
d28c4c4547ef Allow postpad and prepad to expand singleton dimensions (bug #41633)
Mike Miller <mtmiller@ieee.org>
parents: 17744
diff changeset
98
19654
107ec5195a47 prepad.m: Fix str-to-num warnings (bug #44162)
Mike Miller <mtmiller@ieee.org>
parents: 18857
diff changeset
99 %! ## Test with string concatenation (bug #44162)
107ec5195a47 prepad.m: Fix str-to-num warnings (bug #44162)
Mike Miller <mtmiller@ieee.org>
parents: 18857
diff changeset
100 %!assert (prepad ("Octave", 16, "x"), "xxxxxxxxxxOctave")
107ec5195a47 prepad.m: Fix str-to-num warnings (bug #44162)
Mike Miller <mtmiller@ieee.org>
parents: 18857
diff changeset
101 %!assert (prepad ("Octave", 4), "tave")
107ec5195a47 prepad.m: Fix str-to-num warnings (bug #44162)
Mike Miller <mtmiller@ieee.org>
parents: 18857
diff changeset
102
18857
7bbe3658c5ef maint: Use "FIXME:" coding convention in m-files.
Rik <rik@octave.org>
parents: 18513
diff changeset
103 ## FIXME: We need tests for multidimensional arrays.
14363
f3d52523cde1 Use Octave coding conventions in all m-file %!test blocks
Rik <octave@nomad.inbox5.com>
parents: 14138
diff changeset
104
f3d52523cde1 Use Octave coding conventions in all m-file %!test blocks
Rik <octave@nomad.inbox5.com>
parents: 14138
diff changeset
105 %!error prepad ()
f3d52523cde1 Use Octave coding conventions in all m-file %!test blocks
Rik <octave@nomad.inbox5.com>
parents: 14138
diff changeset
106 %!error prepad (1)
f3d52523cde1 Use Octave coding conventions in all m-file %!test blocks
Rik <octave@nomad.inbox5.com>
parents: 14138
diff changeset
107 %!error prepad (1,2,3,4,5)
14406
98cf8aa9f8ba prepad.m: Improve input validation messages and tests.
Rik <octave@nomad.inbox5.com>
parents: 14363
diff changeset
108 %!error <C must be empty or a scalar> prepad ([1,2], 2, ones (2))
98cf8aa9f8ba prepad.m: Improve input validation messages and tests.
Rik <octave@nomad.inbox5.com>
parents: 14363
diff changeset
109 %!error <DIM must be an integer> prepad ([1,2], 2, 2, ones (3))
98cf8aa9f8ba prepad.m: Improve input validation messages and tests.
Rik <octave@nomad.inbox5.com>
parents: 14363
diff changeset
110 %!error <DIM must be an integer> prepad ([1,2], 2, 2, 1.1)
98cf8aa9f8ba prepad.m: Improve input validation messages and tests.
Rik <octave@nomad.inbox5.com>
parents: 14363
diff changeset
111 %!error <L must be a positive scalar> prepad ([1,2], ones (2))
98cf8aa9f8ba prepad.m: Improve input validation messages and tests.
Rik <octave@nomad.inbox5.com>
parents: 14363
diff changeset
112 %!error <L must be a positive scalar> prepad ([1,2], -1)
14363
f3d52523cde1 Use Octave coding conventions in all m-file %!test blocks
Rik <octave@nomad.inbox5.com>
parents: 14138
diff changeset
113