Re: Replacement for the shelve module?

2011-08-20 Thread Gregory Ewing
Robert Kern wrote: That's just incorrect. You shouldn't use (binary) floats for many *accounting* purposes, but for many financial/econometric analyses, floats are de rigeur and work much better than decimals There's a certain accounting package I work with that *does* use floats -- binary

Re: Replacement for the shelve module?

2011-08-20 Thread Chris Angelico
On Sun, Aug 21, 2011 at 1:37 AM, Gregory Ewing greg.ew...@canterbury.ac.nz wrote: There's a certain accounting package I work with that *does* use floats -- binary ones -- for accounting purposes, and somehow manages to get away with it. Not something I would recommend trying at home, though.

Replacement for the shelve module?

2011-08-19 Thread Forafo San
Folks, What might be a good replacement for the shelve module, but one that can handle a few gigs of data. I'm doing some calculations on daily stock prices and the result is a nested list like: [[date_1, floating result 1], [date_2, floating result 2], ... [date_n, floating result n]] However

Re: Replacement for the shelve module?

2011-08-19 Thread Ken Watford
On Fri, Aug 19, 2011 at 11:31 AM, Forafo San ppv.g...@gmail.com wrote: Folks, What might be a good replacement for the shelve module, but one that can handle a few gigs of data. I'm doing some calculations on daily stock prices and the result is a nested list like: For what you're doing, I

Re: Replacement for the shelve module?

2011-08-19 Thread Thomas Jollans
On 19/08/11 17:31, Forafo San wrote: Folks, What might be a good replacement for the shelve module, but one that can handle a few gigs of data. I'm doing some calculations on daily stock prices and the result is a nested list like: [[date_1, floating result 1], [date_2, floating result 2

Re: Replacement for the shelve module?

2011-08-19 Thread Forafo San
On Aug 19, 11:54 am, Thomas Jollans t...@jollybox.de wrote: On 19/08/11 17:31, Forafo San wrote: Folks, What might be a good replacement for the shelve module, but one that can handle a few gigs of data. I'm doing some calculations on daily stock prices and the result is a nested

Re: Replacement for the shelve module?

2011-08-19 Thread Miki Tebeka
You might check one of many binary encoders (like Avro, Thrift ...). The other option is to use a database, sqlite3 is pretty fast (if you schema is fixed). Otherwise you can look at some NoSQL ones (like MongoDB). -- http://mail.python.org/mailman/listinfo/python-list

Re: Replacement for the shelve module?

2011-08-19 Thread Robert Kern
On 8/19/11 10:49 AM, Ken Watford wrote: On Fri, Aug 19, 2011 at 11:31 AM, Forafo Sanppv.g...@gmail.com wrote: Folks, What might be a good replacement for the shelve module, but one that can handle a few gigs of data. I'm doing some calculations on daily stock prices and the result is a nested

Re: Replacement for the shelve module?

2011-08-19 Thread Steven D'Aprano
Forafo San wrote: Folks, What might be a good replacement for the shelve module, but one that can handle a few gigs of data. I'm doing some calculations on daily stock prices and the result is a nested list like: [[date_1, floating result 1], [date_2, floating result 2], ... [date_n

Re: Replacement for the shelve module?

2011-08-19 Thread Robert Kern
On 8/19/11 3:36 PM, Steven D'Aprano wrote: By the way, you know that you should never, ever use floats for currency, right? That's just incorrect. You shouldn't use (binary) floats for many *accounting* purposes, but for many financial/econometric analyses, floats are de rigeur and work

Re: Replacement for the shelve module?

2011-08-19 Thread Dan Stromberg
On Fri, Aug 19, 2011 at 8:31 AM, Forafo San ppv.g...@gmail.com wrote: Folks, What might be a good replacement for the shelve module, but one that can handle a few gigs of data. I'm doing some calculations on daily stock prices and the result is a nested list like: [[date_1, floating result

Re: Replacement for the shelve module?

2011-08-19 Thread Steven D'Aprano
Robert Kern wrote: On 8/19/11 3:36 PM, Steven D'Aprano wrote: By the way, you know that you should never, ever use floats for currency, right? That's just incorrect. You shouldn't use (binary) floats for many *accounting* purposes, but for many financial/econometric analyses, floats are