[erlang-questions] Market data, trading strategies and dropping the last element of a list

Vlad Dumitrescu vladdu55@REDACTED
Tue Dec 19 15:11:54 CET 2006


> > Actually, an implementation is here:
> > http://www.stud.fernuni-hagen.de/q5480035/icfp2003/src-html/ral.html
> Thanks for the pointer. It appears that deleting the last element
> would be O(N), i.e. slow. This is something that I would need to do
> every time I insert a quote, though.
> In essence, if the full price set of prices (time series) is stored
> someplace, the window that strategies use to look at the time series
> is a sliding window. It moves ahead one element at a time as new
> elements (quotes) are added.

Yes, it's not easy to get good performance on all operations...

I was about to suggest a wild idea, but realized it's not what you
want (you need the window to always be at the front of the data
stream). If I get any ideas, I'll let you know.


More information about the erlang-questions mailing list