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

[amibroker] Re: Multi Time Frame: extract daily indicator from intraday data



PureBytes Links

Trading Reference Links

--- In amibroker@xxxxxxxxxxxxxxx, "joe2dixon" <joe2dixon@xxx> wrote:
>
> ang_60:
> 
> Maybe if you try 
> 
> TrRng= ref( ATR(1),-1 );
> 
> It should then look for the True Range for the previous day.
> 
> 
> 

Hi Joe,
thanks for taking the time to look into this matter, but I feel the problem pops up with the "TimeFrameExpand" command... the lines of code before are OK.

As I'm not able to resolve it, I adopted a turnaround, adding two lines to the code of my previous message;

After
TrueRange_Daily = TimeFrameExpand (TrRng, inDaily);

I added:
LastBarofDay = (   DateNum()!= Ref(DateNum(),1)  );
TrueRange_D = IIf (LastBarofDay, Ref(TrueRange_Daily, -1), TrueRange_Daily);


This way the code works as I expected, although it's not satisfactory from a conceptual point of view: I'd wish to see some of the senior users of the list (not to mention TJ) would pop up and explain why the "TimeFrameExpand" has this behaviour(*), but evidently I'm the only one from some thousand users on these list to see a problem with this.

 

(*) which happens on all last 5 minute bar of day EXCEPT the last bar of the last day in test, which from my point of view is even stranger..




------------------------------------

**** IMPORTANT PLEASE READ ****
This group is for the discussion between users only.
This is *NOT* technical support channel.

TO GET TECHNICAL SUPPORT send an e-mail directly to 
SUPPORT {at} amibroker.com

TO SUBMIT SUGGESTIONS please use FEEDBACK CENTER at
http://www.amibroker.com/feedback/
(submissions sent via other channels won't be considered)

For NEW RELEASE ANNOUNCEMENTS and other news always check DEVLOG:
http://www.amibroker.com/devlog/

Yahoo! Groups Links

<*> To visit your group on the web, go to:
    http://groups.yahoo.com/group/amibroker/

<*> Your email settings:
    Individual Email | Traditional

<*> To change settings online go to:
    http://groups.yahoo.com/group/amibroker/join
    (Yahoo! ID required)

<*> To change settings via email:
    mailto:amibroker-digest@xxxxxxxxxxxxxxx 
    mailto:amibroker-fullfeatured@xxxxxxxxxxxxxxx

<*> To unsubscribe from this group, send an email to:
    amibroker-unsubscribe@xxxxxxxxxxxxxxx

<*> Your use of Yahoo! Groups is subject to:
    http://docs.yahoo.com/info/terms/