> Jerome Esteve wrote: >> Is there a way to give an integer value to j when using a[i:j:-1] so >> that the first element of the array can be included in the slice ?
Is this what you are looking for? In [11]: a = np.arange(10) In [12]: a[6::-1] Out[12]: array([6, 5, 4, 3, 2, 1, 0]) I know it's not an integer, but it does indicate "the last (or first) element of the array" -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 [email protected] _______________________________________________ NumPy-Discussion mailing list [email protected] http://mail.scipy.org/mailman/listinfo/numpy-discussion
