NexusFi: Find Your Edge


Home Menu

 





Drawing rectangle at bottom of sceen after each bar


Discussion in NinjaTrader

Updated
      Top Posters
    1. looks_one RBerry with 3 posts (0 thanks)
    2. looks_two futuretrader with 2 posts (1 thanks)
    3. looks_3 Quick Summary with 1 posts (0 thanks)
    4. looks_4 tulanch with 1 posts (1 thanks)
    1. trending_up 3,821 views
    2. thumb_up 2 thanks given
    3. group 2 followers
    1. forum 6 posts
    2. attach_file 0 attachments




 
Search this Thread

Drawing rectangle at bottom of sceen after each bar

  #1 (permalink)
 RBerry 
Toronto, Canada
 
Experience: Beginner
Platform: NinjaTrader
Trading: es
Posts: 5 since Nov 2011
Thanks Given: 11
Thanks Received: 0

Folks,

I'm trying to have a rectangle to draw under each bar at the bottom of price panel. Is there a way in NT7 to do this? I know how to get DrawRectangle() to draw a rectangle at a certain number of ticks above or below a bar, but I want the rectangle to appear at the very bottom of the current price panel under each bar. The colour of the rectangle would vary based on various conditions.

Thanks for any assistance.

RBerry

Started this thread Reply With Quote

Can you help answer these questions
from other members on NexusFi?
Exit Strategy
NinjaTrader
MC PL editor upgrade
MultiCharts
Increase in trading performance by 75%
The Elite Circle
ZombieSqueeze
Platforms and Indicators
NT7 Indicator Script Troubleshooting - Camarilla Pivots
NinjaTrader
 
Best Threads (Most Thanked)
in the last 7 days on NexusFi
Just another trading journal: PA, Wyckoff & Trends
27 thanks
Tao te Trade: way of the WLD
23 thanks
Diary of a simple price action trader
22 thanks
My NQ Trading Journal
14 thanks
GFIs1 1 DAX trade per day journal
9 thanks
  #3 (permalink)
 futuretrader 
Como Italy
 
Experience: Intermediate
Platform: Ninjatrader, customized
Trading: ES
Posts: 525 since Feb 2010
Thanks Given: 471
Thanks Received: 643



RBerry View Post
Folks,

I'm trying to have a rectangle to draw under each bar at the bottom of price panel. Is there a way in NT7 to do this? I know how to get DrawRectangle() to draw a rectangle at a certain number of ticks above or below a bar, but I want the rectangle to appear at the very bottom of the current price panel under each bar. The colour of the rectangle would vary based on various conditions.

Thanks for any assistance.

RBerry

You can do that by overriding the Plot() method. I usually create a DataSeries keyed to the colors, and then refer to that in Plot().

Reply With Quote
  #4 (permalink)
 RBerry 
Toronto, Canada
 
Experience: Beginner
Platform: NinjaTrader
Trading: es
Posts: 5 since Nov 2011
Thanks Given: 11
Thanks Received: 0

Thanks for your rely.
I don't understand the overwrite Plot method. And how would I stipulate bottom of price panel under each bar.

Thanks

Started this thread Reply With Quote
  #5 (permalink)
 futuretrader 
Como Italy
 
Experience: Intermediate
Platform: Ninjatrader, customized
Trading: ES
Posts: 525 since Feb 2010
Thanks Given: 471
Thanks Received: 643

NinjaTrader Version 7

The examples they mention (among the indicators provided with NT) show how to get the bounds. You can also refer to C# help material for how to do graphics - once you're overriding the method you've moved from Ninjascript help to C#. It might seem daunting, but once you get into it you'll find it straightforward at first, and worth the effort if you are interested in custom indicators.

Reply With Quote
Thanked by:
  #6 (permalink)
 tulanch 
Salt Lake City, UT
 
Experience: Intermediate
Platform: SC, NT, MT
Broker: AMP
Trading: NQ ES YM Bonds
Posts: 265 since Mar 2010
Thanks Given: 50
Thanks Received: 387

Does it really need to be a rectangle? Using DrawFixedText - I think one of the overrides let you set the font family and using windings 1,2 or 3 you can do things.... but overwritting the plot is not that hard either... there are numerous examples in the support forum...

Reply With Quote
Thanked by:
  #7 (permalink)
 RBerry 
Toronto, Canada
 
Experience: Beginner
Platform: NinjaTrader
Trading: es
Posts: 5 since Nov 2011
Thanks Given: 11
Thanks Received: 0

Thanks folks for your response. I'll look at the samples you mentioned. If you can point me to more examples on the forum, I'd appreciate it.

Thanks again!

Started this thread Reply With Quote




Last Updated on January 10, 2012


© 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