I have been trying to declare a three dimensional array with the following constraints using numpy in Python 2.7.3:
1.) MyArray(First, Second, Third)
2.) First has 11 elements
3.) Second has 14 elements
4.a) The Third dimension varies in size depending on the element of the First dimension
4.b) If First=8 then Third=988
4.c) Else if First=10 or First=11 then Third=640
4.d) Else Third=494
Is this possible with arrays or should I be using structures?
Thank you in advance,
Several algorithms in NumPy work on arbitrarily strided arrays. However, some algorithms require single-segment arrays. When an irregularly strided array is passed in to such algorithms, a copy is automatically made.