changeset 25761:0f6c81ca5128

maint: merge stable to default.
author Rik <rik@octave.org>
date Thu, 09 Aug 2018 10:54:16 -0700
parents 134939b92d86 (current diff) 2d5bd2cce0dd (diff)
children ecdced9fe445
files
diffstat 1 files changed, 9 insertions(+), 4 deletions(-) [+]
line wrap: on
line diff
--- a/scripts/general/flip.m	Thu Aug 09 10:38:54 2018 -0700
+++ b/scripts/general/flip.m	Thu Aug 09 10:54:16 2018 -0700
@@ -20,27 +20,32 @@
 ## -*- texinfo -*-
 ## @deftypefn  {} {} flip (@var{x})
 ## @deftypefnx {} {} flip (@var{x}, @var{dim})
-## Flip array across dimension @var{dim}.
+## Return a copy of array @var{x} flipped across dimension @var{dim}.
 ##
-## Return a copy of @var{x} flipped about the dimension @var{dim}.
-## @var{dim} defaults to the first non-singleton dimension.
-## For example:
+## If @var{dim} is unspecified it defaults to the first non-singleton
+## dimension.
+##
+## Examples:
 ##
 ## @example
 ## @group
+## ## row vector
 ## flip ([1  2  3  4])
 ##       @result{}  4  3  2  1
 ##
+## ## column vector
 ## flip ([1; 2; 3; 4])
 ##       @result{}  4
 ##           3
 ##           2
 ##           1
 ##
+## ## 2-D matrix along dimension 1
 ## flip ([1 2; 3 4])
 ##       @result{}  3  4
 ##           1  2
 ##
+## ## 2-D matrix along dimension 2
 ## flip ([1 2; 3 4], 2)
 ##       @result{}  2  1
 ##           4  3