[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Code for storing Open high low close of different time frame in arrays ?



PureBytes Links

Trading Reference Links

Thank you Alex  for your answer and the code for your improved version of
the o,h,l,cD functions.
I understand now that I have to store each O,H,L,C for each time frames in
six different array - one for each time frame I need- in order to calculate
whatever indicator I want on that time frame (so on that array's values).
Thank you for the insight. This is new to me.

To everyone who may help me further...
As I am very, very bad in programming,  I would be very grateful I somebody
who has already done something like that with array to store open high low
close of different time frame could send me an example of the code to do it.
So I only have to made minor adjustments to my need .
Or point me were I may find it available.
It would same me a LOT of time. 

Thank you in advance.
Regards
Philippe



> -----Message d'origine-----
> De : unicorn@xxxxxxxxx [mailto:unicorn@xxxxxxxxx] De la part de Alex
Matulich
> Envoyé : vendredi 13 août 2004 18:36
> À : omega-list@xxxxxxxxxx
> Objet : Re: How to code Indicator calculations on multiple time frame
without plotting each
> time frame as data1, data2 etc...?
> 
> Phillipe,
> 
> >To be used in a strategy, i am trying to build an index based on
> >indicator's calculations on six different time frame of the same
> >data on data1.  Do you know how to code that in EL (TS2000i) in a
> >function (or six functions if necessary) to but WITHOUT THE NEED
> >TO PLOT the datas in the six time frames data1, data2, data3 ...?
> >(that would be too heavy to be monitored in real time datafeed with
> >a strategy).
> 
> In data1 you need data having the smallest time increment you will
> use.  For example, if you need to calculate on 30 min bars, 5 min
> bars, 180 min bars, and daily bars, then you need data for 5 minute
> bars.
> 
> You can use HighD, HighW, etc. to get the high, low, and close
> for daily, weekly, monthly, etc. data.  The only problem is that
> these functions assume the day starts at midnight, and includes all
> sessions.  If that is not acceptable, well, I have some replacement
> functions that you can download as a TS2000i ELS.  See
> http://www.purebytes.com/archives/omega/2004/msg01984.html for more
> info.
> 
> For the other intraday bars, you will need to maintain them in
> arrays for open, high, low, and close for each time unit.  So for
> example, for 30 minute bars you would use the last six 5-minute
> bars, every time mod(time,30)=0.
> 
> -Alex