Eric wrote:
... In MATLAB, if I just want the first, fifth and eighth element I might do something like this: b = a([1 5 8]);
On Nov 11, 1:51 pm, Marc 'BlackJack' Rintsch <[EMAIL PROTECTED]> replied:
b = [a[i] for i in [1, 5, 8]]
To which Eric said:
Thanks! It makes sense, but in this case MATLAB seems easier and no less readable. That said, I know better than for a newbie like me to question syntax issues.
If you are using numpy, you may find found the following link useful: http://www.scipy.org/NumPy_for_Matlab_Users --Scott David Daniels [EMAIL PROTECTED] -- http://mail.python.org/mailman/listinfo/python-list