PureBytes Links
Trading Reference Links
|
Okay herman, I want to plot the first 15 minute high and low, and
these values remain the same on all timeframes. This is a step
further from my original qestion.
The codes I came up with work on 1 to 15 minute chart, but for
interval higher than 15 minute it will give the first bar's high and
low, i.e. 30 minute chart gets first 30 minute high and low, 60
minute chart gets first 60 minute high and low, etc.
HooLee
--- In amibroker@xxxxxxxxxxxxxxx, "Herman van den Bergen"
<psytek@xxxx> wrote:
> Thanks for the code HooLee, can you explain what you mean
with: "...to store
> constantly 15 high and low ..."?
>
> herman
>
> -----Original Message-----
> From: hoolee0820 [mailto:hoolee0820@x...]
> Sent: Sunday, May 16, 2004 7:27 PM
> To: amibroker@xxxxxxxxxxxxxxx
> Subject: [amibroker] Re: Ploting a opening range
>
>
> Thank you for your help herman, your codes work, and I've learnt
how
> to use HHV() in these codes too.
>
> Although I asked to plot on a 1 minute chart, having codes worked
> only in one timeframe still buggs me. After some reseach, I found
> that AB does not "compress" TimeNum(), so a DateNum() should be
used.
>
> I modified the codes to:
>
> TimeFrameSet(in15Minute);
> ORh = ValueWhen(DateNum() != Ref(DateNum(),-1), H);
> ORl = ValueWhen(DateNum() != Ref(DateNum(),-1), L);
> TimeFrameRestore();
> OR15h = TimeFrameExpand(ORh, in15Minute);
> OR15l = TimeFrameExpand(ORl, in15Minute);
>
> intrv = IIf(Interval()/60 < 15, 15, Interval()/60);
> Plot(OR15h,WriteVal(intrv, 1.0)+" minute high",colorGreen);
> Plot(OR15l,WriteVal(intrv, 1.0)+" minute low", colorYellow);
> Plot(C,"Close",1,128);
> GraphXSpace=5;
>
> now it returns first 15 minute high, low for 15 minute and lower
> chart, and first bar high, low for other higher timeframe intraday
> chart, I consider this a "good bug" for I can now easily find out
> first 30, 60, 120 minute high and low also.
>
> I still don't know how to store constantly 15 high and low without
> setting up a loop or using a 3rd part DLL, if you have any ideas
I'd
> love to hear.
>
> Thanks again.
>
> HooLee
>
>
>
> --- In amibroker@xxxxxxxxxxxxxxx, "Herman van den Bergen"
> <psytek@xxxx> wrote:
> > Sometimes i can't find my coding errors and I just fiddle
around to
> find
> > another way :-)
> >
> > OR15h = ValueWhen(TimeNum()==094500, HHV(H,15));
> > OR15l = ValueWhen(TimeNum()==094500, LLV(L,15));
> > Plot(OR15h,"15 minute high",colorGreen);
> > Plot(OR15l,"15 minute low", colorYellow);
> > Plot(C,"Close",1,128);
> > GraphXSpace=5;
> >
> > herman
> > -----Original Message-----
> > From: hoolee0820 [mailto:hoolee0820@x...]
> > Sent: Sunday, May 16, 2004 7:51 AM
> > To: amibroker@xxxxxxxxxxxxxxx
> > Subject: [amibroker] Ploting a opening range
> >
> >
> > I'm trying to store and plot first 15 minute hign and low on
a 1
> > minute chart. Hers is the codes:
> >
> > TimeFrameSet(in15Minute);
> > ORh = ValueWhen(TimeNum()==93000, H);
> > ORl = ValueWhen(TimeNum()==93000, L);
> > TimeFrameRestore();
> > OR15h = TimeFrameExpand(ORh, in15Minute);
> > OR15l = TimeFrameExpand(ORl, in15Minute);
> > Plot(OR15h,"15 minute high",colorGreen);
> > Plot(OR15l,"15 minute low", colorYellow);
> >
> > this works correctly on charts with 15 minute (and above) time
> frame,
> > but not on lower time frame. Can someone point out what I did
> wrong?
> >
> > Thanks,
> >
> > HooLee
> >
> >
> >
> > Send BUG REPORTS to bugs@xxxx
> > Send SUGGESTIONS to suggest@xxxx
> > -----------------------------------------
> > Post AmiQuote-related messages ONLY to:
amiquote@xxxxxxxxxxxxxxx
> > (Web page: http://groups.yahoo.com/group/amiquote/messages/)
> > --------------------------------------------
> > Check group FAQ at:
> > http://groups.yahoo.com/group/amibroker/files/groupfaq.html
> >
> >
> > Yahoo! Groups Sponsor
> > ADVERTISEMENT
> >
> >
> >
> >
> >
> > ----------------------------------------------------------------
----
> --------
> > --
> > Yahoo! Groups Links
> >
> > a.. To visit your group on the web, go to:
> > http://groups.yahoo.com/group/amibroker/
> >
> > b.. To unsubscribe from this group, send an email to:
> > amibroker-unsubscribe@xxxxxxxxxxxxxxx
> >
> > c.. Your use of Yahoo! Groups is subject to the Yahoo!
Terms of
> Service.
>
>
>
> Send BUG REPORTS to bugs@xxxx
> Send SUGGESTIONS to suggest@xxxx
> -----------------------------------------
> Post AmiQuote-related messages ONLY to: amiquote@xxxxxxxxxxxxxxx
> (Web page: http://groups.yahoo.com/group/amiquote/messages/)
> --------------------------------------------
> Check group FAQ at:
> http://groups.yahoo.com/group/amibroker/files/groupfaq.html
>
>
> Yahoo! Groups Sponsor
> ADVERTISEMENT
>
>
>
>
>
> --------------------------------------------------------------------
--------
> --
> Yahoo! Groups Links
>
> a.. To visit your group on the web, go to:
> http://groups.yahoo.com/group/amibroker/
>
> b.. To unsubscribe from this group, send an email to:
> amibroker-unsubscribe@xxxxxxxxxxxxxxx
>
> c.. Your use of Yahoo! Groups is subject to the Yahoo! Terms of
Service.
------------------------ Yahoo! Groups Sponsor ---------------------~-->
Make a clean sweep of pop-up ads. Yahoo! Companion Toolbar.
Now with Pop-Up Blocker. Get it for free!
http://us.click.yahoo.com/L5YrjA/eSIIAA/yQLSAA/GHeqlB/TM
---------------------------------------------------------------------~->
Send BUG REPORTS to bugs@xxxxxxxxxxxxx
Send SUGGESTIONS to suggest@xxxxxxxxxxxxx
-----------------------------------------
Post AmiQuote-related messages ONLY to: amiquote@xxxxxxxxxxxxxxx
(Web page: http://groups.yahoo.com/group/amiquote/messages/)
--------------------------------------------
Check group FAQ at: http://groups.yahoo.com/group/amibroker/files/groupfaq.html
Yahoo! Groups Links
<*> To visit your group on the web, go to:
http://groups.yahoo.com/group/amibroker/
<*> 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/
|