[PYTHON MATRIX-SIG] 2D slices of 1D array
Konrad Hinsen
hinsen@ibs.ibs.fr
Wed, 19 Feb 1997 10:03:02 +0100
> The following slice of a 1D array surprised me:
>
> >>> c = array([1,2,3,4,5])
> >>> c
> 1 2 3 4 5
> >>> c[1:3, :]
> EmptyArray
>
> I was expecting either 1,2,3 or an error.
> Is there any rational for this?
None that I can think of. This ought to be an error.
Konrad.
--
-------------------------------------------------------------------------------
Konrad Hinsen | E-Mail: hinsen@ibs.ibs.fr
Laboratoire de Dynamique Moleculaire | Tel.: +33-4.76.88.99.28
Institut de Biologie Structurale | Fax: +33-4.76.88.54.94
41, av. des Martyrs | Deutsch/Esperanto/English/
38027 Grenoble Cedex 1, France | Nederlands/Francais
-------------------------------------------------------------------------------
_______________
MATRIX-SIG - SIG on Matrix Math for Python
send messages to: matrix-sig@python.org
administrivia to: matrix-sig-request@python.org
_______________