[Numpy-discussion] Change in Python/Numpy numerics with Py version 2.6 ?
Christopher Barker
Chris.Barker at noaa.gov
Fri Nov 12 15:56:35 EST 2010
Lou,
as for your confusion about where "acos()" came from:
You are right that if you do:
from math import *
and
from numpy import *
numpy will override some of the math functions, but not "acos()",
because numpy has "arccos()" function instead.
And all of this is a good reminder to not use "import *"
import numpy as np
is the most common way to import numpy these days -- yes it reasults in
a bit of extra typing, but "namespaces are one honking great idea":
http://www.python.org/dev/peps/pep-0020/
-Chris
--
Christopher Barker, Ph.D.
Oceanographer
Emergency Response Division
NOAA/NOS/OR&R (206) 526-6959 voice
7600 Sand Point Way NE (206) 526-6329 fax
Seattle, WA 98115 (206) 526-6317 main reception
Chris.Barker at noaa.gov
More information about the NumPy-Discussion
mailing list