[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

RE: [EquisMetaStock Group] Reentering a trade



PureBytes Links

Trading Reference Links



You cannot reply to this message via email because you have chosen not
to disclose your email address to the group.  Please use this
page to reply.
 




<SPAN 
class=895143916-05122002>Minmo,
<SPAN 
class=895143916-05122002> 
Here 
is something you could try:
<SPAN 
class=895143916-05122002> 
<SPAN 
class=895143916-05122002>Setup:=If(
<SPAN 
class=895143916-05122002>Barssince(Long) > Barssince 
(ExitLong)
<SPAN 
class=895143916-05122002>and
<SPAN 
class=895143916-05122002>Barssince(Long) > Barssince(Short),1,0);  

{these 
two statements tell you that you had a long trigger and that you were stopped 
out of it on the trailing ATR}
<SPAN 
class=895143916-05122002> 
<SPAN 
class=895143916-05122002>Reenter:=
<SPAN 
class=895143916-05122002>Setup=1
<SPAN 
class=895143916-05122002>and
High 
> ValueWhen(1,ExitLong,High + XX)  {this says reenter when you were 
stopped out and now the high of that bar has been exceeded by XX points - 
obviously you can change this to what ever reentry you 
want}.
<SPAN 
class=895143916-05122002> 
I 
haven't tested this out but the basic concept should work for you.  The 
two commands that you'll need are Barssince and 
ValueWhen.
<SPAN 
class=895143916-05122002> 
Good 
Trading,
<SPAN 
class=895143916-05122002> 
Joe 
J.

  <FONT face=Tahoma 
  size=2>-----Original Message-----From: sharpatwork 
  [mailto:mtrimarco@xxxxxxxxxxxxx]Sent: Thursday, December 05, 2002 
  5:33 AMTo: equismetastock@xxxxxxxxxxxxxxxSubject: 
  [EquisMetaStock Group] Reentering a tradeHello 
  all,I'm new to this forum and I'm wondering whether any of Metastock 
  language gurus could help me in some way. :)I'm trying to code in 
  Metastock how to reenter a previous trade in the same direction after a 
  trailing stop has been triggered.Let say I have a very simple TS using 
  2 MA and a TrailingStop calculated on ATR. I'm basing the long trades on 
  ShortMA crossing LongMA and the short trades on the opposite condition. 
  Suppose that the ExitLong condition contains the "OR L <= TrailingStop" 
  statement and, during the backtest, this condition is met. After that, the 
  market turns up again and continues the previous trend. If I was Long, 
  how to code to reenter to the long position?Many thanks for the 
  suggestions and for the time you will dedicate to my 
  question.MimmoTo 
  unsubscribe from this group, send an email 
  to:equismetastock-unsubscribe@xxxxxxxxxxxxxxxYour 
  use of Yahoo! Groups is subject to the <A 
  href="http://docs.yahoo.com/info/terms/";>Yahoo! Terms of Service. 







Yahoo! Groups Sponsor


  ADVERTISEMENT  









To unsubscribe from this group, send an email to:
equismetastock-unsubscribe@xxxxxxxxxxxxxxx





Your use of Yahoo! Groups is subject to the Yahoo! Terms of Service.