NexusFi: Find Your Edge


Home Menu

 





Three Way Filter with Boolean Setup


Discussion in NinjaTrader

Updated
      Top Posters
    1. looks_one sam028 with 1 posts (2 thanks)
    2. looks_two Quick Summary with 1 posts (0 thanks)
    3. looks_3 Big Mike with 1 posts (1 thanks)
    4. looks_4 zeller4 with 1 posts (0 thanks)
    1. trending_up 4,115 views
    2. thumb_up 3 thanks given
    3. group 2 followers
    1. forum 3 posts
    2. attach_file 1 attachments




 
Search this Thread
  #1 (permalink)
 zeller4 
Orlando Florida
 
Experience: Intermediate
Platform: NT8
Trading: CL, NQ, ES, RTY
Posts: 478 since Jun 2009
Thanks Given: 1,419
Thanks Received: 404

Hello,

I've created a small indicator with generic filter descriptions to show the 8 possible outcomes for the use of 3 filters with all the possible outcomes using booleans.

Screenshot attached.

https://screencast.com/t/IQ8mNzlO

Code attached.


I've seen some "elegant code" here and would like to see if there's a better way to produce the results I'm looking for.

at least I know I don't need 90 lines of code, plus I agree some of the resulting plots/colors/drawtext sections could easily be combined or eliminated.

Any takers?
Thanks in Advance.
Kirk

Attached Files
Elite Membership required to download: Three_Way_Filter_Test_v01.cs
Started this thread Reply With Quote

Can you help answer these questions
from other members on NexusFi?
Quantum physics & Trading dynamics
The Elite Circle
is there a better Trade Performance tool for NinjaTrader?
NinjaTrader
MC PL editor upgrade
MultiCharts
Has anyone taken The Confident Trader course from aheadc …
Trading Reviews and Vendors
Brendt Skorupinsky
Trading Reviews and Vendors
 
Best Threads (Most Thanked)
in the last 7 days on NexusFi
ApexTraderFunding.com experience and review
56 thanks
What is Markets Chat (markets.chat) real-time trading ro …
41 thanks
Tao te Trade: way of the WLD
40 thanks
HumbleTraders next chapter
25 thanks
1 Minute Man
19 thanks
  #3 (permalink)
 
Big Mike's Avatar
 Big Mike 
Manta, Ecuador
Site Administrator
Developer
Swing Trader
 
Experience: Advanced
Platform: Custom solution
Broker: IBKR
Trading: Stocks & Futures
Frequency: Every few days
Duration: Weeks
Posts: 50,621 since Jun 2009
Thanks Given: 33,356
Thanks Received: 101,989




Mike



Join the free Markets Chat beta: Real-time Trading Insights

We're here to help: just ask the community or contact our Help Desk

Quick Links: Change your Username or Register as a Vendor
Searching for trading reviews? Review this list
Lifetime Elite Membership: Sign-up for only $149 USD
Exclusive money saving offers from our Site Sponsors: Browse Offers
Report problems with the site: Using the NexusFi changelog thread
Follow me on Twitter Visit my NexusFi Trade Journal Reply With Quote
Thanked by:
  #4 (permalink)
 
sam028's Avatar
 sam028 
Site Moderator
 
Posts: 3,765 since Jun 2009
Thanks Given: 3,825
Thanks Received: 4,629

@zeller4, maybe using integers instead of booleans, and "switch/case" instead of "if" ?

In your code, lets say True == 0, False == 1, so something like:
 
Code
                            
int val;
val = (useFilter1*4)+(useFilter1*2)+(useFilter3*1);
switch (
val)
{
 case 
0
    
Drawtext("A"False"F1: T, F2: T, F3: T", ....
    break;
...

 case 
7
    
DrawText("H",false,"  | F1: F, F2: F, F3: F", ...
    break;

No need to tell you you how to reduce plots/colors/drawtext sections .

Success requires no deodorant! (Sun Tzu)
Follow me on Twitter Reply With Quote
Thanked by:




Last Updated on July 19, 2011


© 2024 NexusFi™, s.a., All Rights Reserved.
Av Ricardo J. Alfaro, Century Tower, Panama City, Panama, Ph: +507 833-9432 (Panama and Intl), +1 888-312-3001 (USA and Canada)
All information is for educational use only and is not investment advice. There is a substantial risk of loss in trading commodity futures, stocks, options and foreign exchange products. Past performance is not indicative of future results.
About Us - Contact Us - Site Rules, Acceptable Use, and Terms and Conditions - Privacy Policy - Sitemap - Downloads - Top
no new posts