NexusFi: Find Your Edge


Home Menu

 





Can I add existing indicators to an indicator I am creating?


Discussion in NinjaTrader

Updated
      Top Posters
    1. looks_one forrestang with 21 posts (0 thanks)
    2. looks_two futuretrader with 3 posts (2 thanks)
    3. looks_3 Fat Tails with 3 posts (4 thanks)
    4. looks_4 Quick Summary with 1 posts (0 thanks)
    1. trending_up 8,111 views
    2. thumb_up 6 thanks given
    3. group 3 followers
    1. forum 27 posts
    2. attach_file 13 attachments




 
Search this Thread

Can I add existing indicators to an indicator I am creating?

  #21 (permalink)
 
forrestang's Avatar
 forrestang 
Chicago IL
 
Experience: None
Platform: Ninja, MT4, Matlab
Broker: CQG, AMP, MB, DTN
Trading: E/U, G/U
Posts: 1,329 since Jun 2010
Thanks Given: 354
Thanks Received: 1,047


futuretrader View Post
I haven't seen that but it seems a good idea in an indicator that combines several others like yours. Though in your case I doubt anyone would want to play around with the ichi parameters - I think that could drive you mad.

Here is what mine looks like now as I have not cleaned it up yet. So it's rather busy at the moment. But I plan on removing most of those things @ the bottom.

Since I don't have any plot options at the moment, and I'm not sure if I'm going to add them, it is only going to be the different lengths for each indicator available. So it's not very many settings on there.

Attached Thumbnails
Click image for larger version

Name:	Prime2011-07-18_033424.jpg
Views:	182
Size:	209.6 KB
ID:	43647  
Started this thread Reply With Quote

Can you help answer these questions
from other members on NexusFi?
Better Renko Gaps
The Elite Circle
Pivot Indicator like the old SwingTemp by Big Mike
NinjaTrader
NT7 Indicator Script Troubleshooting - Camarilla Pivots
NinjaTrader
Exit Strategy
NinjaTrader
Increase in trading performance by 75%
The Elite Circle
 
Best Threads (Most Thanked)
in the last 7 days on NexusFi
Just another trading journal: PA, Wyckoff & Trends
34 thanks
Tao te Trade: way of the WLD
24 thanks
GFIs1 1 DAX trade per day journal
16 thanks
Vinny E-Mini & Algobox Review TRADE ROOM
13 thanks
My NQ Trading Journal
12 thanks
  #22 (permalink)
 futuretrader 
Como Italy
 
Experience: Intermediate
Platform: Ninjatrader, customized
Trading: ES
Posts: 525 since Feb 2010
Thanks Given: 471
Thanks Received: 643


forrestang View Post
Just to clarify, do you mean that I can leave my variables the same way they are declared in my 'variables' section up top. And just change the name down at the bottom?

From This:
 
Code
[Browsable(false)]	// this line prevents the data series from being displayed in the indicator properties dialog, do not remove
        [XmlIgnore()]		// this line ensures that the indicator can be saved/recovered as part of a chart template, do not remove
        public DataSeries TrendState
        {
            get { return trendState; }
        }

To this:
 
Code
[Browsable(false)]	// this line prevents the data series from being displayed in the indicator properties dialog, do not remove
        [XmlIgnore()]		// this line ensures that the indicator can be saved/recovered as part of a chart template, do not remove
        public DataSeries 1_TrendState
        {
            get { return trendState; }
        }

Didn't see this post. No, you'd need to add the Gui Display name description:

 
Code
        [Category("Speech")]
        [Description("Master:  Enables speech synthesis alerts and installs toolstrip toggle.")]
        [Gui.Design.DisplayName("1. Master for Speech")]
        public bool UseSpeech
        {
            get { return speech; }
            set { speech = value; }
        }

Reply With Quote
Thanked by:
  #23 (permalink)
 
forrestang's Avatar
 forrestang 
Chicago IL
 
Experience: None
Platform: Ninja, MT4, Matlab
Broker: CQG, AMP, MB, DTN
Trading: E/U, G/U
Posts: 1,329 since Jun 2010
Thanks Given: 354
Thanks Received: 1,047



futuretrader View Post
Didn't see this post. No, you'd need to add the Gui Display name description:

 
Code
        [Category("Speech")]
        [Description("Master:  Enables speech synthesis alerts and installs toolstrip toggle.")]
        [Gui.Design.DisplayName("1. Master for Speech")]
        public bool UseSpeech
        {
            get { return speech; }
            set { speech = value; }
        }

Ah cool!

I didn't know about that option. So it's just adding this one line to my parameter blocks for each one I want to rename?
 
Code
 [Gui.Design.DisplayName("1. Master for Speech")]

Started this thread Reply With Quote
  #24 (permalink)
 
forrestang's Avatar
 forrestang 
Chicago IL
 
Experience: None
Platform: Ninja, MT4, Matlab
Broker: CQG, AMP, MB, DTN
Trading: E/U, G/U
Posts: 1,329 since Jun 2010
Thanks Given: 354
Thanks Received: 1,047


forrestang View Post
New idea......

The trading I'm doing is partially dependent on pullbacks to the 13ma. And attached is a picture of what my Market Analyzer looks like now.

Right now I will usually consider a pb complete if price gets a minimum of 2 tics within that ma to begin to look for a trade. So typically once it gets there, I start putting my cross hair on that bar, and looking at the values of the H/L of that bar and the 13ema to see if it's right.

I'm thinking I can add that in the indicator, so that when price is within 2 tics of that ma, I can have it displayed in Market Analyzer.

Then the problem would be if I use a different value for a different instrument. CL for example I would give it 4 tics since it moves faster.

Hmmmm..........?

Idea..... I could just add that condition in the market anaylzer via the 'cell conditions' block by adding the 13 ma as a new column. The problem would be that I coudln't set it for each instruemnt.

Also... it would trigger EVERY time price was near it. Which isn't all bad, but I would like it to feel a bit more 'integrated.'

So I'm thinking the logic will be using a flag to decide when to NOT ignore price being near the 13ema.......

 
Code
If (TrendState == True)   //price makes a New LL/HH beyond the blue/red cloud.  Logic already built
{
   Flag = true  //flag so we know to begin looking for a pb to 13ma.  Logic here already as well
}

If (Flag == true)
{
   If(price == 13ema)   //build in tolerance here as well plus/minus tic size
   {
      pbToEma[0] = true   //This is the alert that I will have built into a dataSeries for Market Analyzer
   }
}

If(pbToEma[0] == true)
{
   If(TrendState == False)   //trend no longer happening, so we no longer care if price approaches ma, and time to reset
   {
      Flag = false   //reset the flag, so we are no longer looking for pb to 13ema
   }
}

Started this thread Reply With Quote
  #25 (permalink)
 
Fat Tails's Avatar
 Fat Tails 
Berlin, Europe
Market Wizard
 
Experience: Advanced
Platform: NinjaTrader, MultiCharts
Broker: Interactive Brokers
Trading: Keyboard
Posts: 9,888 since Mar 2010
Thanks Given: 4,242
Thanks Received: 27,102


forrestang View Post
Here is what mine looks like now as I have not cleaned it up yet. So it's rather busy at the moment. But I plan on removing most of those things @ the bottom.

If you serialize the plots by using code, you can remove the original plot options by adding the line

 
Code
PlotsConfigurable = false;
to the Initialize() section.

Reply With Quote
  #26 (permalink)
 
forrestang's Avatar
 forrestang 
Chicago IL
 
Experience: None
Platform: Ninja, MT4, Matlab
Broker: CQG, AMP, MB, DTN
Trading: E/U, G/U
Posts: 1,329 since Jun 2010
Thanks Given: 354
Thanks Received: 1,047

@Fat Tails

Would that mean that I couldn't add the configurable option to be able to adjust the plots on the indicator itself at the bottom? I planned on adding that in at some point.

Attached Thumbnails
Click image for larger version

Name:	Prime2011-07-18_061005.jpg
Views:	181
Size:	136.5 KB
ID:	43656  
Started this thread Reply With Quote
  #27 (permalink)
 
Fat Tails's Avatar
 Fat Tails 
Berlin, Europe
Market Wizard
 
Experience: Advanced
Platform: NinjaTrader, MultiCharts
Broker: Interactive Brokers
Trading: Keyboard
Posts: 9,888 since Mar 2010
Thanks Given: 4,242
Thanks Received: 27,102


forrestang View Post
@ Fat Tails

Would that mean that I couldn't add the configurable option to be able to adjust the plots on the indicator itself at the bottom? I planned on adding that in at some point.

The PlotsConfigurable option has nothing to do with what will be displayed on your chart.

NinjaTrader has an in-built serialization of plots. This serialization allows you to select the colors, dashstyle and plotstyle of your plots in a way that it can be saved as part of a template or part of a workspace.

However, if you want more options, such as down colors and up colors, you need to do the serialization manually and you do not need the in-built serialization any more. When I code indicators, I

-> either use the in-built serialization (do nothing)
-> or I serialize all plots via code (define properties for up- and down color, plotstyle, dashstyle and plotwidth) and set PlotsConfigurable = false;

Just try and see what happens, your PC will not explode.

Reply With Quote
Thanked by:
  #28 (permalink)
 
forrestang's Avatar
 forrestang 
Chicago IL
 
Experience: None
Platform: Ninja, MT4, Matlab
Broker: CQG, AMP, MB, DTN
Trading: E/U, G/U
Posts: 1,329 since Jun 2010
Thanks Given: 354
Thanks Received: 1,047


forrestang View Post
Ah cool!

I didn't know about that option. So it's just adding this one line to my parameter blocks for each one I want to rename?
 
Code
 [Gui.Design.DisplayName("1. Master for Speech")]

@futuretrader
Didn't do much with my script yesterday. I probably won't till this weekend. But I did add that line in just to try it out.

Added it to the first three user inputs for the part of my script that references the ZZ indicator.

Attached Thumbnails
Click image for larger version

Name:	Prime2011-07-19_022648.jpg
Views:	167
Size:	166.7 KB
ID:	43784  
Started this thread Reply With Quote




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 - Downloads - Top
no new posts