Ticket #151 (closed enhancement: wontfix)

Opened 11 months ago

Last modified 2 months ago

Support fancy indexing in row iterator

Reported by: faltet Owned by: somebody
Priority: minor Component: PyTables
Version: 2.1 Keywords: fancy indexing Row iterator
Cc:

Description

It could be handy to support fancy indexing the Row iterators, so that the next could be possible:

for row in t:
    print "-->", row[[2,1]]

where the third and second fields are selected.

While this should be relatively easy to implement, one should check the impact on performance as well.

Change History

Changed 2 months ago by faltet

  • status changed from new to closed
  • resolution set to wontfix

I've considered implementing this, but unfortunately NumPy doesn't offer a provision for fancy indexing of record elements of recarrays. In addition, doing this in the Row extension would represent a cost similar to doing it in python space, so I think it is better that this sort of niceties would be done by the user and not clutter the extension with code that will be used quite infrequently.

Closing the ticket.

Note: See TracTickets for help on using tickets.