OmniTrader Professional Forum OmniTrader Professional Forum
forums calendars search
today this week
register logon control panel Forum Rules
You are currently browsing as a guest.
You should logon to access more features
A Self-Moderated Community - ALL MEMBERS, PLEASE READ!
Vote for Members who contribute the most to your trading, and help us moderate content within the Forums.

This message cannot be deleted. It is the first message of the thread.
Administrators or moderators may choose to delete the entire thread


Posts: 603

Joined: 7/11/2007
Location: Braintree, MA

User Profile
Subject : Syntax help
Posted : 5/16/2022 8:35 AM
Post #32017


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?

Deleting message 32017 : Syntax help

Nirvana Systems
For any problems or issues please contact our Webmaster at