diff options
author | Alan McIntyre <alan.mcintyre@local> | 2008-07-03 03:51:46 +0000 |
---|---|---|
committer | Alan McIntyre <alan.mcintyre@local> | 2008-07-03 03:51:46 +0000 |
commit | 94bc330296e01d8fc0cb14aba1354ddb6d8587cc (patch) | |
tree | 1137428631e3d56ed3251a732e82dfd8778547c0 /numpy/lib/scimath.py | |
parent | 24af452d6573d66faedff2b4b98993a8c0664e97 (diff) | |
download | numpy-94bc330296e01d8fc0cb14aba1354ddb6d8587cc.tar.gz |
Use the implicit "import numpy as np" made available to all doctests instead of an explicit
import.
Remove ">>>" from bartlett plotting example since it currently requires matplotlib.
Diffstat (limited to 'numpy/lib/scimath.py')
-rw-r--r-- | numpy/lib/scimath.py | 16 |
1 files changed, 7 insertions, 9 deletions
diff --git a/numpy/lib/scimath.py b/numpy/lib/scimath.py index f35c87578..d3965668d 100644 --- a/numpy/lib/scimath.py +++ b/numpy/lib/scimath.py @@ -46,8 +46,6 @@ def _tocomplex(arr): Examples -------- - >>> import numpy as np - First, consider an input of type short: >>> a = np.array([1,2,3],np.short) @@ -246,7 +244,7 @@ def log10(x): -------- (We set the printing precision so the example can be auto-tested) - >>> import numpy as np; np.set_printoptions(precision=4) + >>> np.set_printoptions(precision=4) >>> log10([10**1,10**2]) array([ 1., 2.]) @@ -276,7 +274,7 @@ def logn(n, x): -------- (We set the printing precision so the example can be auto-tested) - >>> import numpy as np; np.set_printoptions(precision=4) + >>> np.set_printoptions(precision=4) >>> logn(2,[4,8]) array([ 2., 3.]) @@ -306,7 +304,7 @@ def log2(x): -------- (We set the printing precision so the example can be auto-tested) - >>> import numpy as np; np.set_printoptions(precision=4) + >>> np.set_printoptions(precision=4) >>> log2([4,8]) array([ 2., 3.]) @@ -336,7 +334,7 @@ def power(x, p): Examples -------- (We set the printing precision so the example can be auto-tested) - >>> import numpy as np; np.set_printoptions(precision=4) + >>> np.set_printoptions(precision=4) >>> power([2,4],2) array([ 4, 16]) @@ -368,7 +366,7 @@ def arccos(x): Examples -------- - >>> import numpy as np; np.set_printoptions(precision=4) + >>> np.set_printoptions(precision=4) >>> arccos(1) 0.0 @@ -397,7 +395,7 @@ def arcsin(x): Examples -------- (We set the printing precision so the example can be auto-tested) - >>> import numpy as np; np.set_printoptions(precision=4) + >>> np.set_printoptions(precision=4) >>> arcsin(0) 0.0 @@ -426,7 +424,7 @@ def arctanh(x): Examples -------- (We set the printing precision so the example can be auto-tested) - >>> import numpy as np; np.set_printoptions(precision=4) + >>> np.set_printoptions(precision=4) >>> arctanh(0) 0.0 |