NexusFi: Find Your Edge


Home Menu

 





Multiple plots for StrategyPlot in same panel


Discussion in NinjaTrader

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




 
Search this Thread

Multiple plots for StrategyPlot in same panel

  #1 (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,489 since Jun 2009
Thanks Given: 33,256
Thanks Received: 101,698

Is there a way to have multiple plots/dataseries in the same panel of a StrategyPlot?

For example, StrategyPlot(0) - but I need to set two different Values to represent two separate plots within the same panel. I realize I can create StrategyPlot(1), but doing so creates a new panel.

Mike



Join the free Markets Chat beta: one platform, all the trade rooms!

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 Started this thread Reply With Quote

Can you help answer these questions
from other members on NexusFi?
Better Renko Gaps
The Elite Circle
Strategy stop orders partially filled
EasyLanguage Programming
REcommedations for programming help
Sierra Chart
Footprint for strategy Builder
NinjaTrader
What broker to use for trading palladium futures
Commodities
 
Best Threads (Most Thanked)
in the last 7 days on NexusFi
Funded Trader platforms
68 thanks
Spoo-nalysis ES e-mini futures S&P 500
21 thanks
Trading with Intuition
18 thanks
GFIs1 1 DAX trade per day journal
15 thanks
The Trading Pit "Futures VIP" Account Journal
15 thanks
  #3 (permalink)
 grimReaper 
Los Angeles, CA
 
Posts: 50 since Nov 2011



Big Mike View Post
Is there a way to have multiple plots/dataseries in the same panel of a StrategyPlot?

For example, StrategyPlot(0) - but I need to set two different Values to represent two separate plots within the same panel. I realize I can create StrategyPlot(1), but doing so creates a new panel.

Mike

Not at my home computer, so can't provide actual code, but you just mimic NT-generated code and rename. Don't forget the properties.

Reply With Quote
  #4 (permalink)
 grimReaper 
Los Angeles, CA
 
Posts: 50 since Nov 2011

By StrategyPlot, I assume you mean indicator? And are you sure this is NT and not EL, for example?. Anyway...

 
Code
protected override void Initialize(){

	Add(new Plot(Color.FromKnownColor(KnownColor.Red), PlotStyle.Line, "Name1"));
        Add(new Plot(Color.FromKnownColor(KnownColor.Black), PlotStyle.Line, "Name2"));
        Overlay				= false;
}

protected override void OnBarUpdate(){
        Name1.Set(Open[0]);
        Name2.Set(Close[0]);

}
	
	
//Properties	
	[Browsable(false)]	
        [XmlIgnore()]		
        public DataSeries Name1
        {
            get { return Values[0]; }
        }


	[Browsable(false)]	
        [XmlIgnore()]		
        public DataSeries Name2
        {
            get { return Values[1]; }
        }

Reply With Quote
  #5 (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,489 since Jun 2009
Thanks Given: 33,256
Thanks Received: 101,698


grimReaper View Post
By StrategyPlot, I assume you mean indicator? And are you sure this is NT and not EL, for example?

No, I mean StrategyPlot() as in Strategy not Indicator. And yes, I mean what I said. NinjaTrader. LOL!



Mike



Join the free Markets Chat beta: one platform, all the trade rooms!

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 Started this thread Reply With Quote
  #6 (permalink)
 
gregid's Avatar
 gregid 
Wrocław, Poland
 
Experience: Intermediate
Platform: NinjaTrader, Racket
Trading: Ockham's razor
Posts: 650 since Aug 2009
Thanks Given: 320
Thanks Received: 623

@Big Mike

Use the following:

 
Code
                            
StrategyPlot(0).PanelUI 1;
StrategyPlot(1).PanelUI 1
To keep both in Panel 1

Reply With Quote
Thanked by:
  #7 (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,489 since Jun 2009
Thanks Given: 33,256
Thanks Received: 101,698


gregid View Post
@Big Mike

Use the following:

 
Code
                            
StrategyPlot(0).PanelUI 1;

StrategyPlot(1).PanelUI 1
To keep both in Panel 1

Awesome, thank you.

Mike



Join the free Markets Chat beta: one platform, all the trade rooms!

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 Started this thread Reply With Quote
  #8 (permalink)
 grimReaper 
Los Angeles, CA
 
Posts: 50 since Nov 2011


Big Mike View Post
Awesome, thank you.

Mike

Please remember to use the thanks button.

Reply With Quote
  #9 (permalink)
 grimReaper 
Los Angeles, CA
 
Posts: 50 since Nov 2011


Big Mike View Post
No, I mean StrategyPlot() as in Strategy not Indicator. And yes, I mean what I said. NinjaTrader. LOL!



Mike

@Big Mike

In case you're desperately trying to get back at me for one my posts in another thread, I'll clarify that you clearly didn't recognize where I was coming from in my second post here. If StrategyPlot(0) and StrategyPlot(1) alter the plot window when dealing with >1 data series as you mention , then this doesn't resemble a call you'd find in an OOP language like C#, so confirming whether this was NT is a non-trivial question...

Reply With Quote




Last Updated on February 21, 2013


© 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