changeset 6158:57aeb18f161d

[project @ 2006-11-13 23:52:35 by jwe]
author jwe
date Mon, 13 Nov 2006 23:52:35 +0000
parents 045038e0108a
children 645605133a6f
files scripts/ChangeLog scripts/plot/mesh.m
diffstat 2 files changed, 4 insertions(+), 2 deletions(-) [+]
line wrap: on
line diff
--- a/scripts/ChangeLog	Mon Nov 13 22:22:54 2006 +0000
+++ b/scripts/ChangeLog	Mon Nov 13 23:52:35 2006 +0000
@@ -1,5 +1,7 @@
 2006-11-13  John W. Eaton  <jwe@octave.org>
 
+	* plot/mesh.m: Use proper dimensions for y in call to repmat.
+
 	* miscellaneous/substruct.m: New function.
 
 	* testfun/assert.m: Force orientation to match when comparing
--- a/scripts/plot/mesh.m	Mon Nov 13 22:22:54 2006 +0000
+++ b/scripts/plot/mesh.m	Mon Nov 13 23:52:35 2006 +0000
@@ -42,8 +42,8 @@
   elseif (nargin == 3)
     if (isvector (x) && isvector (y) && ismatrix (z))
       if (rows (z) == length (y) && columns (z) == length (x))
-        x = repmat(x(:)', length (y), 1);
-        y = repmat(y(:), 1, length (x));
+        x = repmat(x(:)', rows (z), 1);
+        y = repmat(y(:), 1, columns (z));
       else
         msg = "mesh: rows (z) must be the same as length (y) and";
         msg = sprintf ("%s\ncolumns (z) must be the same as length (x)", msg);