# HG changeset patch # User John W. Eaton # Date 1247168487 14400 # Node ID b317debeb8284b8f0dda54ec06b971c626bae3ee # Parent 7b74a7fd4761a1949721a84789cc94d3dc694f3b data.cc (Fones, Fzeros, Ftrue, Ffalse): update docstring diff -r 7b74a7fd4761 -r b317debeb828 src/ChangeLog --- a/src/ChangeLog Thu Jul 09 15:22:21 2009 -0400 +++ b/src/ChangeLog Thu Jul 09 15:41:27 2009 -0400 @@ -1,3 +1,7 @@ +2009-07-09 John W. Eaton + + * data.cc (Fones, Fzeros, Ftrue, Ffalse): Update docstrings. + 2009-07-08 John W. Eaton * graphics.cc (convert_cdata): Return NaN for NaN values in cdata. diff -r 7b74a7fd4761 -r b317debeb828 src/data.cc --- a/src/data.cc Thu Jul 09 15:22:21 2009 -0400 +++ b/src/data.cc Thu Jul 09 15:41:27 2009 -0400 @@ -1,7 +1,7 @@ /* Copyright (C) 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002, - 2003, 2004, 2005, 2006, 2007, 2008 John W. Eaton + 2003, 2004, 2005, 2006, 2007, 2008, 2009 John W. Eaton Copyright (C) 2009 Jaroslav Hajek This file is part of Octave. @@ -3608,7 +3608,10 @@ @deftypefnx {Built-in Function} {} ones (@var{n}, @var{m}, @var{k}, @dots{})\n\ @deftypefnx {Built-in Function} {} ones (@dots{}, @var{class})\n\ Return a matrix or N-dimensional array whose elements are all 1.\n\ -The arguments are handled the same as the arguments for @code{eye}.\n\ +If invoked with a single scalar integer argument, return a square\n\ +matrix of the specified size. If invoked with two or more scalar\n\ +integer arguments, or a vector of integer values, return an array with\n\ +given dimensions.\n\ \n\ If you need to create a matrix whose values are all the same, you should\n\ use an expression like\n\ @@ -3654,7 +3657,7 @@ @deftypefnx {Built-in Function} {} zeros (@var{n}, @var{m}, @var{k}, @dots{})\n\ @deftypefnx {Built-in Function} {} zeros (@dots{}, @var{class})\n\ Return a matrix or N-dimensional array whose elements are all 0.\n\ -The arguments are handled the same as the arguments for @code{eye}.\n\ +The arguments are handled the same as the arguments for @code{ones}.\n\ \n\ The optional argument @var{class}, allows @code{zeros} to return an array of\n\ the specified type, for example\n\ @@ -4131,7 +4134,7 @@ @deftypefnx {Built-in Function} {} false (@var{n}, @var{m})\n\ @deftypefnx {Built-in Function} {} false (@var{n}, @var{m}, @var{k}, @dots{})\n\ Return a matrix or N-dimensional array whose elements are all logical 0.\n\ -The arguments are handled the same as the arguments for @code{eye}.\n\ +The arguments are handled the same as the arguments for @code{ones}.\n\ @end deftypefn") { return fill_matrix (args, false, "false"); @@ -4143,7 +4146,7 @@ @deftypefnx {Built-in Function} {} true (@var{n}, @var{m})\n\ @deftypefnx {Built-in Function} {} true (@var{n}, @var{m}, @var{k}, @dots{})\n\ Return a matrix or N-dimensional array whose elements are all logical 1.\n\ -The arguments are handled the same as the arguments for @code{eye}.\n\ +The arguments are handled the same as the arguments for @code{ones}.\n\ @end deftypefn") { return fill_matrix (args, true, "true");