|
Buffalo
 Elite
  Posts: 603
Joined: 7/11/2007
Location: Braintree, MA
User Profile |
All
Messing around with an ATM method and want to use a filter block to reproduce the ATM market states but having trouble getting the a NO Trade market state (MS where we don't allow trades) syntax defined in a filter block. Filter blocks work to ALLOW signals to pass when certain criteria are met. The MS in ATM is written so that when that specific criteria is met we have 0 trades allowed in ATM which is NOT the same as don't allow trades directly. The MS says when this is true we won't trade, but my filter blocks need to say when this situation is NOT true we will allow signals - The opposite effectively.
I tried 1 filter block with "NOT (XXX(16,2.5,1,14)[1] = 0)" (BTW no "" was used in actual filter) on the $VIX and another filter block with "NOT (YYYY(23,0.6)[1] > YYYY(23,0.6)[2] AND RSI(9)[1] > 90)" on SPY but NO signals get passed at all with these engaged.
The filter blocks need to PASS signals when XXX(16,2.5,1,14)[1] = 0 and YYYY(23,0.6)[1] > YYYY(23,0.6)[2] AND RSI(9)[1] > 90 is NOT true. What is the proper syntax here? NOT should work.
You can't just reverse it - IOW XXXX(16,2.5,1,14)[1] = 1 or -1 or YYYY(23,0.6)[1] < YYYY(23,0.6)[2] AND RSI(9)[1] <= 90. For sure the second is NOT the same.
Any ideas?
|
|
Barry Cohen
 Idol
      Posts: 2285
Joined: 1/1/1900
User Profile |
Try 3 separate filter blocks:
Symbol $VIX:
VBX4_Gap_Dir(16,2.5,1,14)[1] <> 0
Symbol SPY:
RSI(9)[1] <= 90
Symbol SPY:
CoralTrend(23,0.6)[1] <= CoralTrend(23,0.6)[2]
|
|
Buffalo
 Elite
  Posts: 603
Joined: 7/11/2007
Location: Braintree, MA
User Profile |
Thx Barry!
|
|
SteveL
 Veteran
  Posts: 132
Joined: 2/15/2007
Location: Boulder, CO
User Profile |
Barry and Bill,
I believe the two conditions Barry specified for the SPY should be in the same filter block, and "Any" (i.e., an OR condition) should be selected. If either of those two conditions are true, then the signal should get through. Only if both conditions are false should it be blocked.
|