PureBytes Links
Trading Reference Links
|
Sorry, a few too many mistakes even for rough code in
my previous post. Here it is again slightly more
cleaned up:
Vars: SellDay(0),HighToday(0),Upside(0),
SellSetupType2(0),SellPoint1(0),SellPoint2(0);
If MarketPosition = -1 Then Begin
SellDay = 0;
SellSetupType2 = 0;
End;
If Time Data2 = Sess1EndTime and Date <> Date[1]
Then Begin
SellDay = SellDay[1];
If XXXX {whatever your daily bar reqt's are to
establish a sell day} Then
SellDay = 1;
End;
If Time Data2 = 8:35 {start time for 5 min bars}
Then Begin
HighToday = 0;
If SellDay = 1 Then Begin
SellPoint1 = Open Data2 - XXXX {your measure of
desired downside distance below the open for
your first type of intraday sell reqt., which
could be based on either data1 or data2 as you
wish};
SellPoint2 = Open Data2 - {2 ticks, e.g.};
End;
End;
Upside = {whatever your reqt. is for how high
price must go to constitute an upside failure for
your second type of intraday sell reqt., again based
on either data1 or data2};
If High Data2 > HighToday Then Begin
HighToday = High Data2;
If HighToday > Upside Then
SellSetupType2 = 1;
End;
If Time Data2 >= 835 and Time Data2 <= XXXX {your time
limit for what you want to have occur occur}
Then Begin
Sell at SellPoint1 Stop;
If SellSetupType2 = 1 Then
Sell at SellPoint2 Stop;
End;
|