Sorry if this isn't the right thread -- there's a few now.
But for an example of using both positional and keyword index parameters:
I maintain a library (gridded) that provides an abstraction over data on various types of grid (in this case generally Oceanographic model output) -- they can be rectangular grids, curvilinear, unstructured triangular, .... The point of the library is to save the user from having to understand how all those grids work and, rather, be able to work with the data as if it were a continuous field. For example, if I want to know the sea surface temperature at a given location, I need to figure out what cell that location is in, what the values are at the corners of that cell, and then interpolate over the cell.
After abstracting that, one can create a gridded.Variable object, and then do:
and get the value at those coordinates.
So it would be pretty nifty to do:
sea_surface_temp[-78.123, 28.432], which of course I could do with Python as it is.
But in some instance, there is more than one way to interpolate, so it would be great to have:
sea_surface_temp[-78.123, 28.432, interp='linear']
and that would require having mixed positional and keyword index parameters.
-CHB