reshape docstrings conflicting
Hi all, The ndarray.reshape docstring claims: "Also always returns a view or raises a ValueError if that is impossible." whereas fromnumeric.reshape claims: "This will be a new view object if possible; otherwise, it will be a copy." while the code paths for both functions are the same. So, which one of these is correct? Or, does ndarray.reshape always return a view? This is not immediately obvious looking at the code... I'll fix up the docstrings once I know. -- Pauli Virtanen
On Sat, Apr 26, 2008 at 11:29 AM, Pauli Virtanen <pav@iki.fi> wrote:
Hi all,
The ndarray.reshape docstring claims:
"Also always returns a view or raises a ValueError if that is impossible."
whereas fromnumeric.reshape claims:
"This will be a new view object if possible; otherwise, it will be a copy."
while the code paths for both functions are the same.
So, which one of these is correct? Or, does ndarray.reshape always return a view? This is not immediately obvious looking at the code...
I'll fix up the docstrings once I know.
Hi Pauli, I noticed that you removed the ReST markup of the tables in sort documentation. I think you should leave it in. Chuck
On Sat, Apr 26, 2008 at 11:24 AM, Charles R Harris <charlesr.harris@gmail.com> wrote:
I noticed that you removed the ReST markup of the tables in sort documentation. I think you should leave it in.
I haven't tried to render it, but I think he just changed the tables from ReST's grid table to ReST's simple table format: http://docutils.sourceforge.net/docs/user/rst/quickref.html#tables -- Jarrod Millman Computational Infrastructure for Research Labs 10 Giannini Hall, UC Berkeley phone: 510.643.4014 http://cirl.berkeley.edu/
Hi Chuck, Charles R Harris wrote: [clip]
I noticed that you removed the ReST markup of the tables in sort documentation. I think you should leave it in.
Also the simplified table syntax ======== ======== ======== header 1 header 2 header 3 ======== ======== ======== line 1a line 1b line 1c line 2a line 2b line 2c ======== ======== ======== is valid ReST [1], and easier to type and IMHO to read than the gridded tables: +----------+----------+----------+ | header 1 | header 2 | header 3 | +==========+==========+==========+ | line 1a | line 1b | line 1c | | line 2a | line 2b | line 2c | +----------+----------+----------+ If you strongly prefer the gridded syntax, I can revert it back. Pauli .. [1] http://docutils.sourceforge.net/docs/ref/rst/restructuredtext.html#simple-ta...
participants (3)
-
Charles R Harris -
Jarrod Millman -
Pauli Virtanen