diff options
author | Charles Harris <charlesr.harris@gmail.com> | 2009-03-22 06:56:44 +0000 |
---|---|---|
committer | Charles Harris <charlesr.harris@gmail.com> | 2009-03-22 06:56:44 +0000 |
commit | 8364447b9b50854c0b12650423728a7d168374b6 (patch) | |
tree | cce491dcd0801e22b00b094e3510cfc809ec17a0 | |
parent | 6d7e43e5fccae9914eaefee26781a6c4669afebf (diff) | |
download | numpy-8364447b9b50854c0b12650423728a7d168374b6.tar.gz |
Mention the trunc ufunc as new in 1.3 and note this in its docstring.
-rw-r--r-- | doc/release/1.3.0-notes.rst | 14 | ||||
-rw-r--r-- | numpy/core/code_generators/ufunc_docstrings.py | 12 |
2 files changed, 16 insertions, 10 deletions
diff --git a/doc/release/1.3.0-notes.rst b/doc/release/1.3.0-notes.rst index 60f8abce9..fc7edddfe 100644 --- a/doc/release/1.3.0-notes.rst +++ b/doc/release/1.3.0-notes.rst @@ -109,6 +109,7 @@ New ufuncs #. rad2deg - converts radians to degrees, same as the degrees ufunc. #. log2 - base 2 logarithm. #. exp2 - base 2 exponential. +#. trunc - truncate floats to nearest integer towards zero. #. logaddexp - add numbers stored as logarithms and return the logarithm of the result. #. logaddexp2 - add numbers stored as base 2 logarithms and return the base 2 @@ -120,12 +121,12 @@ Masked arrays Several new features and bug fixes, including: * structured arrays should now be fully supported by MaskedArray - (r6463, r6324, r6305, r6300, r6294...) - * Minor bug fixes (r6356, r6352, r6335, r6299, r6298) - * Improved support for __iter__ (r6326) - * made baseclass, sharedmask and hardmask accesible to the user (but - read-only) - * doc update + (r6463, r6324, r6305, r6300, r6294...) + * Minor bug fixes (r6356, r6352, r6335, r6299, r6298) + * Improved support for __iter__ (r6326) + * made baseclass, sharedmask and hardmask accesible to the user (but + read-only) + * doc update gfortran support on windows ~~~~~~~~~~~~~~~~~~~~~~~~~~~ @@ -199,6 +200,7 @@ New public C defines are available for ARCH specific code through numpy/npy_cpu. * NPY_CPU_SPARC: 32 bits sparc * NPY_CPU_SPARC64: 64 bits sparc * NPY_CPU_S390: S390 + * NPY_CPU_IA64: ia64 * NPY_CPU_PARISC: PARISC New macros for CPU endianness has been added as well (see internal changes diff --git a/numpy/core/code_generators/ufunc_docstrings.py b/numpy/core/code_generators/ufunc_docstrings.py index 29a504b52..08f131c23 100644 --- a/numpy/core/code_generators/ufunc_docstrings.py +++ b/numpy/core/code_generators/ufunc_docstrings.py @@ -508,7 +508,7 @@ add_newdoc('numpy.core.umath', 'bitwise_and', Examples -------- - We've seen that 13 is represented by ``00001101``. Similary, 17 is + We have seen that 13 is represented by ``00001101``. Similary, 17 is represented by ``00010001``. The bit-wise AND of 13 and 17 is therefore ``000000001``, or 1: @@ -537,7 +537,7 @@ add_newdoc('numpy.core.umath', 'bitwise_or', When calculating the bit-wise OR between two elements, ``x`` and ``y``, each element is first converted to its binary representation (which works - just like the decimal system, only now we're using 2 instead of 10): + just like the decimal system, only now we are using 2 instead of 10): .. math:: x = \\sum_{i=0}^{W-1} a_i \\cdot 2^i\\\\ y = \\sum_{i=0}^{W-1} b_i \\cdot 2^i, @@ -605,7 +605,7 @@ add_newdoc('numpy.core.umath', 'bitwise_xor', When calculating the bit-wise XOR between two elements, ``x`` and ``y``, each element is first converted to its binary representation (which works - just like the decimal system, only now we're using 2 instead of 10): + just like the decimal system, only now we are using 2 instead of 10): .. math:: x = \\sum_{i=0}^{W-1} a_i \\cdot 2^i\\\\ y = \\sum_{i=0}^{W-1} b_i \\cdot 2^i, @@ -711,6 +711,10 @@ add_newdoc('numpy.core.umath', 'trunc', >>> np.ceil(a) array([-1., -1., -0., 0., 1., 1., 2.]) + Notes + ----- + .. versionadded:: 1.3.0 + """) add_newdoc('numpy.core.umath', 'conjugate', @@ -2269,7 +2273,7 @@ add_newdoc('numpy.core.umath', 'deg2rad', Notes ----- .. versionadded:: 1.3.0 - + ``deg2rad(x)`` is ``x * pi / 180``. Examples |