This is an archival dump of old wiki content --- see scipy.org for current material

Abstract

The returned array is the absolute values of the given array. An alias for abs(arr) function

Signature


Function

absolute(arr)


Returns

return
The returned array is the absolute values of the given array.

Arguments

arr
The given array.

Details

xxx

Examples

   1 >>> from numpy import *
   2 >>> absolute(-1)
   3 1
   4 >>> absolute(array([-1.2, 1.2]))
   5 array([ 1.2,  1.2])
   6 >>> absolute(1.2+1j)
   7 1.5620499351813308

Notes

xxx

See Also

abs : abs() is an alias.

SciPy: absolute (last edited 2015-10-24 17:48:23 by anonymous)