PureBytes Links
Trading Reference Links
|
Moscar
> I would like to know if it is any way that I can include different data
> periods in a system.
> For example mix a condition where a daily CCI(55) go to up and a
> intraday 10 minute CCI(55) also go up?
> I'm using Metastock Pro V7.22.
> Hope someone can help me.
If you have a formula for CCI (MetaStock code that simulates the underlying hardwired CCI function)
then you can apply the timing principles used in my daily indicators for intraday charts. Each
component function needs to be assembled before all are brought together to give the daily value.
>From the following Standard Deviation formula (necessary for CCI) you can see that it's not just a
matter of roughly putting a few lines of code together.
The good news is that only one daily timing mechanism is necessary, and a Simple Moving Average is
much more compact than Standard Deviation.
So to answer your question, yes it can be done.
Roy
{Daily Standard Deviation Basic}
{2004 Roy Larsen, rlarsen@xxxxxxxxxxxxxx}
{for use on intraday charts}
N:=Input("Daily Standard Deviation Periods",2,26,10);
X:=Input("Deviations",0,9,2);
G:=LastValue(Highest(Sum(DayOfWeek()<>
ValueWhen(2,1,DayOfWeek()),5))=5);
J:=DayOfMonth()<>ValueWhen(2-G,1,DayOfMonth()) OR G;
K:=ValueWhen(1,J,ValueWhen(2-G,1,C));
M:=(Cum(J*K)-ValueWhen(N+1,J,Cum(J*K)))/N;
N1:=LastValue((N>5)*5); N2:=LastValue((N>10)*10);
N3:=LastValue((N>15)*15); N4:=LastValue((N>20)*20);
Y:=Power(M-ValueWhen(1,J,K),2)+
Power(M-ValueWhen(2,J,K),2)+
(N>2)*Power(M-ValueWhen(3,J,K),2)+
(N>3)*Power(M-ValueWhen(4,J,K),2)+
(N>4)*Power(M-ValueWhen(5,J,K),2)+
(N>5)*Power(M-ValueWhen(N1+1,J,K),2)+
(N>6)*Power(M-ValueWhen(N1+2,J,K),2)+
(N>7)*Power(M-ValueWhen(N1+3,J,K),2)+
(N>8)*Power(M-ValueWhen(N1+4,J,K),2)+
(N>9)*Power(M-ValueWhen(N1+5,J,K),2)+
(N>10)*Power(M-ValueWhen(N2+1,J,K),2)+
(N>11)*Power(M-ValueWhen(N2+2,J,K),2)+
(N>12)*Power(M-ValueWhen(N2+3,J,K),2)+
(N>13)*Power(M-ValueWhen(N2+4,J,K),2)+
(N>14)*Power(M-ValueWhen(N2+5,J,K),2)+
(N>15)*Power(M-ValueWhen(N3+1,J,K),2)+
(N>16)*Power(M-ValueWhen(N3+2,J,K),2)+
(N>17)*Power(M-ValueWhen(N3+3,J,K),2)+
(N>18)*Power(M-ValueWhen(N3+4,J,K),2)+
(N>19)*Power(M-ValueWhen(N3+5,J,K),2)+
(N>20)*Power(M-ValueWhen(N4+1,J,K),2)+
(N>21)*Power(M-ValueWhen(N4+2,J,K),2)+
(N>22)*Power(M-ValueWhen(N4+3,J,K),2)+
(N>23)*Power(M-ValueWhen(N4+4,J,K),2)+
(N>24)*Power(M-ValueWhen(N4+5,J,K),2)+
(N>25)*Power(M-ValueWhen(N4+6,J,K),2);
X*Sqrt(Y/N);
------------------------ 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/BefplB/TM
--------------------------------------------------------------------~->
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/
|