Slicing matrix

A

Anthony Liu

I am using numarray.

Suppose I have
array([[ 0, 1, 2, 3, 4],
[ 5, 6, 7, 8, 9],
[10, 11, 12, 13, 14],
[15, 16, 17, 18, 19],
[20, 21, 22, 23, 24]])

How do I easily slice out [0,1,2] or [1,2,3] or
[2,7,12] or [7,12,17] and put it in a list?

I checked the documentation at
http://www.esrf.fr/computing/bliss/python2/NumArray/html/node26.html
, but could not get it.

Thanks.

__________________________________________________
Do You Yahoo!?
Tired of spam? Yahoo! Mail has the best spam protection around
http://mail.yahoo.com
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,769
Messages
2,569,582
Members
45,061
Latest member
KetonaraKeto

Latest Threads

Top