diff options
author | Charles Harris <charlesr.harris@gmail.com> | 2015-01-22 18:42:10 -0500 |
---|---|---|
committer | Charles Harris <charlesr.harris@gmail.com> | 2015-01-22 18:42:10 -0500 |
commit | 5b714c7ecd46ed8e730afc8f37f8b8d1faf36497 (patch) | |
tree | af8e78dec7a66c244bac38b9f18de1931fed3e3a /numpy/add_newdocs.py | |
parent | 723a1ee58493061b4f1701bb173f648712e3addc (diff) | |
parent | 1bd0b4e8f176cd80e81b5f50832db5f8ba1ee1e9 (diff) | |
download | numpy-5b714c7ecd46ed8e730afc8f37f8b8d1faf36497.tar.gz |
Merge pull request #5482 from ahaldane/recordarray_doc
DOC: improve record/structured array nomenclature & guide
Diffstat (limited to 'numpy/add_newdocs.py')
-rw-r--r-- | numpy/add_newdocs.py | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/numpy/add_newdocs.py b/numpy/add_newdocs.py index 73efdb6a9..66b889cc9 100644 --- a/numpy/add_newdocs.py +++ b/numpy/add_newdocs.py @@ -4629,7 +4629,7 @@ add_newdoc('numpy.core.multiarray', 'ndarray', ('view', >>> print x [(1, 20) (3, 4)] - Using a view to convert an array to a record array: + Using a view to convert an array to a recarray: >>> z = x.view(np.recarray) >>> z.a @@ -5875,17 +5875,18 @@ add_newdoc('numpy.core.multiarray', 'dtype', >>> np.dtype(np.int16) dtype('int16') - Record, one field name 'f1', containing int16: + Structured type, one field name 'f1', containing int16: >>> np.dtype([('f1', np.int16)]) dtype([('f1', '<i2')]) - Record, one field named 'f1', in itself containing a record with one field: + Structured type, one field named 'f1', in itself containing a structured + type with one field: >>> np.dtype([('f1', [('f1', np.int16)])]) dtype([('f1', [('f1', '<i2')])]) - Record, two fields: the first field contains an unsigned int, the + Structured type, two fields: the first field contains an unsigned int, the second an int32: >>> np.dtype([('f1', np.uint), ('f2', np.int32)]) |