Paul recently requested help with testing and debugging MLab.py, and I offered to help out. He then sent me this note:
"Paul F. Dubois" wrote:
MLab.py started out as a package that was supposed to give numpy a Matlab look and feel. So useful questions are: are there really useful things that should be added?
I can't answer these questions myself. Interestingly enough, despite the fact that I came to NumPy having used MATLAB heavily for five years (and one dissertation), I have made very little use of MLab.py. I'm wondering if anyone is, indeed, using it.
As for trying to give numpy a MATLAB look and feel, I question the usefulness of that. NumPy looks and feels a little different than MATLAB, and, frankly, I like NumPy's feel better for the most part (now that rich comparisons have been added, anyway). The one thing that MATLAB has that NumPy doesn't, that I really miss, is list indexing. Having to use put and take is so much less elegant! I'm sure this isn't the least bit trivial to add, however. (is it even possible, given Python's idea of slicing?)
Anyway, what I do think MATLAB does provide, and MLab.py should, is a whole bunch of utility functions for various common manipulations.
Do we really have what we have correct?
Most of all, these is no test routine for it. If you could make one following the model of the test.py in directory Test, it would be great. The idea is to have something that does not require the runner of the test to know anything. It just runs silently unless something is wrong.
I certainly could write up a test routine. I will start work on that. In the meantime, before I put too much effort into it, I'd really like some feedback on what people want MLab.py to be, if they see using it at all.
As I said above, I'm not sure trying to give NumPy a MATLAB feel is a useful goal, so what is left is having all those handy functions. Perhaps we could shift away from MLab.py, and turn it into Utilities.py, which could use MATLAB (and other user experience) as guidance as to what utilities to include.
I'd really like folks' feedback on this before I put too much work into something no one uses, or will use.