diff options
author | Travis Oliphant <oliphant@enthought.com> | 2006-09-16 02:08:59 +0000 |
---|---|---|
committer | Travis Oliphant <oliphant@enthought.com> | 2006-09-16 02:08:59 +0000 |
commit | 8b6db6e885dec95dda7bbe2001d95bdee63e6cf1 (patch) | |
tree | 66e012c2479c69c935529d6f56488829f2433995 /numpy/lib | |
parent | f74f1d14f0768650a7dd5327944ddcc82f0d892d (diff) | |
download | numpy-8b6db6e885dec95dda7bbe2001d95bdee63e6cf1.tar.gz |
Fix ticket #188 by returning the name of the dtype objects for data-type objects without fields or sub-arrays that are in correct byte-order
Diffstat (limited to 'numpy/lib')
-rw-r--r-- | numpy/lib/twodim_base.py | 3 | ||||
-rw-r--r-- | numpy/lib/utils.py | 5 |
2 files changed, 5 insertions, 3 deletions
diff --git a/numpy/lib/twodim_base.py b/numpy/lib/twodim_base.py index 512b6bf53..d79fd03c6 100644 --- a/numpy/lib/twodim_base.py +++ b/numpy/lib/twodim_base.py @@ -143,7 +143,7 @@ def vander(x, N=None): X[:,i] = x**(N-i-1) return X -def histogram2d(x,y, bins=10, range=None, normed=False): +def histogram2d(x,y, bins=10, range=None, normed=False): """histogram2d(x,y, bins=10, range=None, normed=False) -> H, xedges, yedges Compute the 2D histogram from samples x,y. @@ -159,7 +159,6 @@ def histogram2d(x,y, bins=10, range=None, normed=False): The histogram array is a count of the number of samples in each two dimensional bin. Setting normed to True returns a density rather than a bin count. - Data falling outside of the edges are not counted. """ import numpy as np try: diff --git a/numpy/lib/utils.py b/numpy/lib/utils.py index b6ee51b91..981ec6de5 100644 --- a/numpy/lib/utils.py +++ b/numpy/lib/utils.py @@ -238,7 +238,10 @@ def info(object=None,maxwidth=76,output=sys.stdout,toplevel='numpy'): if object is None: info(info) - elif isinstance(object, types.StringType): + elif isinstance(object, ndarray): + import numpy.numarray as nn + nn.info(object, output=output, numpy=1) + elif isinstance(object, str): if _namedict is None: _namedict, _dictlist = _makenamedict(toplevel) numfound = 0 |