From 9f88ecbc10e7a1f56e2eb1b8445184263111a1cf Mon Sep 17 00:00:00 2001 From: Travis Oliphant Date: Thu, 1 Jun 2006 21:11:10 +0000 Subject: Comment changes and change var and std to divide by N instead of N-1 --- numpy/lib/index_tricks.py | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to 'numpy/lib/index_tricks.py') diff --git a/numpy/lib/index_tricks.py b/numpy/lib/index_tricks.py index 6f9d14e3e..c1516a976 100644 --- a/numpy/lib/index_tricks.py +++ b/numpy/lib/index_tricks.py @@ -18,9 +18,9 @@ makemat = matrix.matrix # contributed by Stefan van der Walt def unravel_index(x,dims): - """Convert a flat index into an index tuple for a matrix of given shape. + """Convert a flat index into an index tuple for an array of given shape. - e.g. for a 2x2 matrix, unravel_index(2,(2,2)) returns (1,0). + e.g. for a 2x2 array, unravel_index(2,(2,2)) returns (1,0). Example usage: p = x.argmax() @@ -314,6 +314,7 @@ class ndenumerate(object): def __iter__(self): return self + class ndindex(object): """Pass in a sequence of integers corresponding to the number of dimensions in the counter. This iterator -- cgit v1.2.1