PDA

View Full Version : Entry Pice Problem


PauDor
7th November 2004, 12:15 PM
Hi there,

I have been working on a breakout system for trading the long side of the NASDAQ with CFD,s.

I wish to enter trades on the open, the day after a the entry trigger if the open price is greater than or equal to the previos days close.

My question is how can I incorporate the above into the system below and if anyone can pick up any fundamental problems with the system below as I am still learning how to write these systems ?

LongEntryTrigger :=

{Bollinger Band Width 12 Mth low + 3%}
(((BBandTop(C,20,S,2.25)-BBandBot(C,20,S,2.25))/Mov(C,20,S))*100)<(LLV((((BBandTop(C,20,S,2.25)-BBandBot(C,20,S,2.25))/Mov(C,20,S))*100),260))+3 AND

{Bollinger Band Width 12 Mth high - 12%}
(((BBandTop(C,20,S,2)-BBandBot(C,20,S,2))/Mov(C,20,S))*100)<(HHV((((BBandTop(C,20,S,2)-BBandBot(C,20,S,2))/Mov(C,20,S))*100),260))-8.5 AND

{3% Consolidation Highest Close to Lowest Close in the last 10 days}
(((Ref(HHV(C,7),-1)-Ref(LLV(C,7),-1))/Ref(LLV(C,7),-1))*100)<3 AND

CLOSE>=BBandTop(C,15,S,1.65)AND

(VOLUME>Mov(V,7,E) OR Mov(OBV(),3,E)>Mov(OBV(),30,E) OR Mov(V,3,E)>Mov(V,10,E)) AND



(ATR(260)/Mov(C,260,S))*100>=2.5 AND


LinRegSlope(C,14)>0 AND

MFI(14)<75 ;

LongEntryPrice := OPEN;
LongExitTrigger := Cross(Ref(LLV(C,4),-1),L) ;
LongExitPrice :=
Ref(LLV(C,4),-1);
LongInitialStop := 0;

ExtFml( "TradeSim.Initialize");
ExtFml("TradeSim.SetStartRecordDate",1,1,1997);
ExtFml("TradeSim.SetStopRecordDate",1,7,2004);
ExtFml("TradeSim.EnableDelayOfEntryByOneBar");

ExtFml( "TradeSim.EnablePriceFilter") ;
ExtFml("TradeSim.RecordTrades",
"PD The Sqeeze Long Cross 3DH NASDAQ",
Long,
longEntryTrigger,
longEntryPrice,
longInitialStop,
longExitTrigger ,
longExitPrice ,
START);

Forever grateful if you could show the way,

Cheers,

Paul

Jose
7th November 2004, 08:20 PM
I wish to enter trades on the open, the day after a the entry trigger if the open price is greater than or equal to the previos days close.


Example for the entry:

BBT&#58;=BBandTop&#40;C,20,S,2.25&#41;;
BBB&#58;=BBandBot&#40;C,20,S,2.25&#41;;

EntryCondition&#58;=

&#123;Bollinger Band Width 12 Mth low + 3%&#125;
&#40;BBT-BBB&#41;/Mov&#40;C,20,S&#41;*100
<LLV&#40;&#40;&#40;BBT-BBB&#41;/Mov&#40;C,20,S&#41;*100&#41;,260&#41;+3

&#123;Bollinger Band Width 12 Mth high - 8.5%&#125;
AND &#40;BBT-BBB&#41;/Mov&#40;C,20,S&#41;*100
<HHV&#40;&#40;&#40;BBT-BBB&#41;/Mov&#40;C,20,S&#41;*100&#41;,260&#41;-8.5

&#123;3% Consolidation Highest Close to Lowest Close
in the last 7 days&#125;
AND &#40;Ref&#40;HHV&#40;C,7&#41;,-1&#41;-Ref&#40;LLV&#40;C,7&#41;,-1&#41;&#41;
/Ref&#40;LLV&#40;C,7&#41;,-1&#41;*100<3

AND C>=BBandTop&#40;C,15,S,1.65&#41;

AND &#40;V>Mov&#40;V,7,E&#41;
OR Mov&#40;OBV&#40;&#41;,3,E&#41;>Mov&#40;OBV&#40;&#41;,30,E&#41;
OR Mov&#40;V,3,E&#41;>Mov&#40;V,10,E&#41;&#41;

AND &#40;ATR&#40;260&#41;/Mov&#40;C,260,S&#41;&#41;*100>=2.5

AND LinRegSlope&#40;C,14&#41;>0

AND MFI&#40;14&#41;<75;

LongEntryTrigger&#58;=
Ref&#40;EntryCondition,-1&#41; AND O>=Ref&#40;C,-1&#41;;



...can pick up any fundamental problems with the system

You've got so much going on there, that it's a wonder that this system gives any signals at all.

Try breaking up each system component into separate indicators, and see if the individual signals match your expectancy.

For example:

BBT&#58;=BBandTop&#40;C,20,S,2.25&#41;;
BBB&#58;=BBandBot&#40;C,20,S,2.25&#41;;

&#123;Bollinger Band Width 12 Mth low + 3%&#125;
&#40;BBT-BBB&#41;/Mov&#40;C,20,S&#41;*100
<LLV&#40;&#40;&#40;BBT-BBB&#41;/Mov&#40;C,20,S&#41;*100&#41;,260&#41;+3

Does the above signals look Ok on a chart?
Are they getting too late into rallies?
Too many downtrends/ranges?
If so, how can it be changed/adjusted?
If not, what about scrapping this part of the code?
Etc...

jose '-)

PauDor
10th November 2004, 11:33 PM
Thanks Jose, that works fine.

Understand that the system in it,s present form gives limited signals but now the exit is correct I can work on increasing the amount of buy signals as you suggested.

Thanks heaps "again"

Paul