[Numpy-discussion] Adding keyword to asarray and asanyarray.
ben.root at ou.edu
Thu Mar 5 11:42:24 EST 2015
dare I say... datetime64/timedelta64 support?
On Thu, Mar 5, 2015 at 11:40 AM, Charles R Harris <charlesr.harris at gmail.com
> Hi All,
> This is apropos gh-5634 <https://github.com/numpy/numpy/pull/5634>, a PR
> adding a precision keyword to asarray and asanyarray. The PR description is
> The precision keyword differs from the current dtype keyword in the
>> following way.
>> - It specifies a minimum precision. If the precision of the input is
>> greater than the specified precision, the input precision is preserved.
>> - Complex types are preserved. A specifies floating precision applies
>> to the dtype of the real and complex parts separately.
>> For example, both complex128 and float64 dtypes have the
>> same precision and an array of dtype float64 will be unchanged if the
>> specified precision is float32.
>> Ideally the precision keyword would be pushed down into the array
>> constructor so that the resulting dtype could be determined before the
>> array is constructed, but that would require adding new functions as the
>> current constructors are part of the API and cannot have their
>> signatures changed.
> The name of the keyword is open to discussion, as well as its acceptable
> values. And of course, anything else that might come to mind ;)
> NumPy-Discussion mailing list
> NumPy-Discussion at scipy.org
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the NumPy-Discussion