- Katılım
- 23 Eki 2020
- Mesajlar
- 1,823
=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-= From:gadee333 <gadee333 [at] hotmail [dot] com> To:equismetastock [at] yahoogroups [dot] com <equismetastock [at] yahoogroups [dot] com> Sent: Monday, May 15, 2006 3:36 AM Subject: [EquisMetaStock Group] Querry help... =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-= I am using real time data. I want to plot an indicator fulfilling folloing conditions on 5 min chart. 1. CCI last 7 days ( not 7 periods ) 2. Buy signal should be when CCI(7days) crosses above - 100 3. Sell signal should be when CCI(7days) crosses below - 110 will any one please help. Anil Desai =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-= From:Roy Larsen <rlarsen [at] man.quik.co.nz> To:equismetastock [at] yahoogroups [dot] com <equismetastock [at] yahoogroups [dot] com> Date:Monday, May 15, 2006, 3:44:22 AM Subject: [EquisMetaStock Group] Querry help... =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-= Hi Anil Is this something like what you had in mind? "Z" is the 7-period daily CCI-Standard (no bells or whistles). Regards Roy |
|
{Daily CCI-7 Standard w/Crossovers} {C 2006 Roy Larsen} {www.metastocktips.co.nz} {For use on intraday charts} G:=LastValue(Highest(Sum(DayOfWeek()<> ValueWhen(2,1,DayOfWeek()),5))=5); J:=DayOfMonth()<>ValueWhen(2-G,1,DayOfMonth()) OR G {OR Cum(1)=LastValue(Cum(1))} {for dynamic last bar}; Hd:=ValueWhen(1,J,ValueWhen(2-G,1,HighestSince(1,J,H))); Hd:=ValueWhen(1,Hd>0,Hd); Ld:=ValueWhen(1,J,ValueWhen(2-G,1,LowestSince(1,J,L))); Ld:=ValueWhen(1,Ld>0,Ld); Cd:=ValueWhen(1,J,ValueWhen(2-G,1,C)); {CCI calculation} X:=(Cd+Hd+Ld)/3; Y:=(X+ValueWhen(2,J,X)+ValueWhen(3,J,X)+ ValueWhen(4,J,X)+ValueWhen(5,J,X)+ ValueWhen(6,J,X)+ValueWhen(7,J,X))/7; Z:=(Abs(Y-X)+Abs(y-ValueWhen(2,J,X))+ Abs(Y-ValueWhen(3,J,X))+Abs(Y-ValueWhen(4,J,X))+ Abs(Y-ValueWhen(5,J,X))+Abs(Y-ValueWhen(6,J,X))+ Abs(Y-ValueWhen(7,J,X)))/7; Z:=(X-Y)/(Z*0.015); Buy:=Cross(Z,-100); Sell:=Cross(-110,Z); Buy; Sell; |
=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-= From:gadee333 <gadee333 [at] hotmail [dot] com> To:equismetastock [at] yahoogroups [dot] com <equismetastock [at] yahoogroups [dot] com> Date:Tuesday, May 16, 2006, 2:11:32 AM Subject: [EquisMetaStock Group] Querry help... =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-= Thanks Roy you certainly gave me the direction. Let me test wether this can give the result the way i wanted. I will post the result. Anil | |
| |
Source / From: |