PureBytes Links
Trading Reference Links
|
Thanks, Claud.
Good to hear that the original Lunar phase code is still working as it
should after 5 years. Don't forget to adjust signals by one minute in 64
years from now! |:-D
jose '-)
http://www.metastocktools.com
--- In equismetastock@xxxxxxxxxxxxxxx, Claud Baruch <claudb@xxxx>
wrote:
> Jose, actually I've had this indicator in my list since 2000. But I'll
> abide by your direction in the future/
>
> Claud
>
>
> Jose Silva wrote:
>
> Claud, I would be grateful if you would kindly *not remove* the
> copyright header from any of my published MS code.
>
> As for the indicator's accuracy, one only has to plot its signals below
> any complete chart, and take a look out the window to verify if they
> match.
> Seeing is believing. ;)
>
>
> jose '-)
> http://www.metastocktools.com
>
>
>
> Original Lunar cycle indicator:
>
> MetaStock -> Tools -> Indicator Builder -> New
> Copy and paste formula below.
>
> ===========
> Lunar cycle
> ===========
> ---8<---------------------------
>
> { Full/New Moon signals indicator MkVI }
> { Accurate to within 1 minute per 69 years }
> { ©Copyright 2002-2004 jose silva }
> { For personal use only }
> { http://www.metastocktools.com }
>
> { Plots +1 signal on Full Moon; -1 on New Moon }
> { If FM/NM falls on a holiday or weekend,
> signal is plotted on the nearest trading day }
> { Warning: will not plot last FM/NM signal
> until it is confirmed on next trade day }
>
> { Input your world time zone }
> TZ:=Input("Your Time Zone? (-12 to +12hrs)",
> -12,12,10);
>
> { Lunar cycle }
> LunarMonth:=29.530589;
> Offset:=7.254621;
>
> { Calendar }
> leap:=Frac(Year()/4)=0 AND Frac(Year()/100)<>0
> OR Frac(Year()/400)=0;
> y:=Year()*365+Int(Year()/4)
> -Int(Year()/100)+Int(Year()/400);
> m:=
> If(Month()=2,31-leap,
> If(Month()=3,59,
> If(Month()=4,90,
> If(Month()=5,120,
> If(Month()=6,151,
> If(Month()=7,181,
> If(Month()=8,212,
> If(Month()=9,243,
> If(Month()=10,273,
> If(Month()=11,304,
> If(Month()=12,334,
> -leap)))))))))));
> CurrentDay:=y+m+DayOfMonth()-TZ/24-Offset;
>
> { Full/New Moon }
> FM:=Frac(CurrentDay/LunarMonth);
> NM:=Frac(FM+0.5);
>
> { Plot in own window below chart }
> (PeakBars(1,FM,.01)=0)-(PeakBars(1,NM,.01)=0)
>
> ---8<---------------------------
>
>
>
> --- In equismetastock@xxxxxxxxxxxxxxx, Claud Baruch
<claudb@xxxx> wrote:
>
>
> >>{plots +1 signal on Full Moon & -1 on New Moon}
> >>{if FM/NM falls on a holiday or weekend, signal is plotted on the
> >>closest trading day}
> >>
> >>Span:=Input("Full/New Moon signal, total span in days",1,9,1);
> >>TZ:=
> >> Input("Time Zone (-12 to +12hrs)",-12,12,-10);
> >>
> >>LunarMonth:=29.530589;
> >>Offset:=7.254621;
> >>
> >>leap:=Frac(Year()/4)=0 AND Frac(Year()/100)<>0
> >> OR Frac(Year()/400)=0;
> >>y:=Year()*365+Int(Year()/4)
> >> -Int(Year()/100)+Int(Year()/400);
> >>m:=
> >> If(Month()=2,31-leap,
> >> If(Month()=3,59,
> >> If(Month()=4,90,
> >> If(Month()=5,120,
> >> If(Month()=6,151,
> >> If(Month()=7,181,
> >> If(Month()=8,212,
> >> If(Month()=9,243,
> >> If(Month()=10,273,
> >> If(Month()=11,304,
> >> If(Month()=12,334,
> >> -leap)))))))))));
> >>CurrentDay:=y+m+DayOfMonth()+TZ/24-Offset;
> >>
> >>FM:=Frac(CurrentDay/LunarMonth);
> >>NM:=Frac(FM+0.5);
> >>
> >>0;Ref(Alert(FM>Ref(FM,1),Span),Span/2)+
> >>Ref(Alert(NM>Ref(NM,1),Span),Span/2)*-1
>
>
>Al Dina wrote:
>
> Hello,
>
> A while ago, I believe that Jose or someone else posted the code for
> the Full Moon/New Moon. Does anybody have that code and do they
> know if it is accurate?
>
> Any help would be appreciated.
>
> Thanks,
> Al
Yahoo! Groups Links
<*> To visit your group on the web, go to:
http://groups.yahoo.com/group/equismetastock/
<*> To unsubscribe from this group, send an email to:
equismetastock-unsubscribe@xxxxxxxxxxxxxxx
<*> Your use of Yahoo! Groups is subject to:
http://docs.yahoo.com/info/terms/
|