Say I have a 3D array such as:
>>> arr = numpy.arange(36).reshape(3, 4, 3)
>>> arr
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, 25, 26],
[27, 28, 29],
[30, 31, 32],
[33, 34, 35]]])
How do I extract the nth value from each innermost row?
If I were to take the values for index 1, how can pull out the following?
array([[ 1, 4, 7, 10],
[13, 16, 19, 22],
[25, 28, 31, 34]])
or
array([ 1, 4, 7, 10, 13, 16, 19, 22, 25, 28, 31, 34])