NinjaTrader Support Forum  
X

Attention!

This website will be down for maintenance from Friday May 24th at 6PM MDT until Saturday May 25th at 11AM MDT. We apologize for the inconvenience. If you need assistance during this time, please email sales@ninjatrader.com


Go Back   NinjaTrader Support Forum > NinjaScript Development Support > Strategy Development

Strategy Development Support for the development of custom automated trading strategies using NinjaScript.

Reply
 
Thread Tools Display Modes
Old 07-20-2012, 02:21 PM   #1
arbuthnot
Senior Member
 
Join Date: Feb 2012
Posts: 177
Thanks: 41
Thanked 12 times in 10 posts
Default Renko bars for entries, time-based bars for exits

Hi guys

I have a chart with Renko bars in panel 1 and time-based bars in panel 2.

I have a strategy which, at the moment, is totally dependent on the Renko bars. But ideally, it would depend on the Renko bars for entries and the time-based bars for exits using a trailing stop.

How can I bring this about? I'm guessing this must have something to do with 'multi-instrument' techniques, but I'd be very grateful for any specific pointers.

Thanks very much in advance.
Last edited by arbuthnot; 07-20-2012 at 02:24 PM.
arbuthnot is offline  
Reply With Quote
Old 07-20-2012, 02:29 PM   #2
NinjaTrader_Matthew
NinjaTrader Customer Service
 
NinjaTrader_Matthew's Avatar
 
Join Date: Apr 2010
Location: Denver, CO, USA
Posts: 4,777
Thanks: 158
Thanked 565 times in 556 posts
Default

Hello,

You are on the right track: you would need a multi-instrument script to accomplish this.

Please have a look at our reference sample on Entering on one time frame and exiting on another:

http://www.ninjatrader.com/support/f...ead.php?t=5787

I would also suggest studying the information from our Help Guide under Multi-Time Frame & Instruments:

http://www.ninjatrader.com/support/h...nstruments.htm
NinjaTrader_Matthew is offline  
Reply With Quote
Old 07-20-2012, 02:46 PM   #3
arbuthnot
Senior Member
 
Join Date: Feb 2012
Posts: 177
Thanks: 41
Thanked 12 times in 10 posts
Default

Thanks very much, Matthew. I obviously need to study these in depth.

But just for the moment, just one question: are there any additional complications if the Bars objects are of different types, in this case: Renko and time-based? (In the examples, they are both time-based.)

The main reason I'm asking this is that Renko and minute bars are usually very much 'out of sequence', and I'm wondering of this might have an impact.

Again, much obliged for any ideas.
arbuthnot is offline  
Reply With Quote
Old 07-20-2012, 03:01 PM   #4
NinjaTrader_Matthew
NinjaTrader Customer Service
 
NinjaTrader_Matthew's Avatar
 
Join Date: Apr 2010
Location: Denver, CO, USA
Posts: 4,777
Thanks: 158
Thanked 565 times in 556 posts
Default

Yes, it's critical to understand how the OHLC data will be references in a multi-series script.

The High[2] renko is not necessarily the same bar High[2] on a minute interval.

I would recommend taking some time Printing values to get a grasp on how this data is going to be referenced and take note of what could potentially affect your strategy.
NinjaTrader_Matthew is offline  
Reply With Quote
Old 07-20-2012, 03:34 PM   #5
arbuthnot
Senior Member
 
Join Date: Feb 2012
Posts: 177
Thanks: 41
Thanked 12 times in 10 posts
Default

Thanks again, Matthew. I've noted all the points you've made. There's a lot of study to be done here.

Cheers.
arbuthnot is offline  
Reply With Quote
Reply

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
entry at bars where exits take place Stephan123 Strategy Development 1 01-28-2012 12:52 PM
Multi Time frame when "load data based on bars" for chart ct General Programming 2 07-19-2011 07:15 AM
How to add an indicator based on time-based bars to a tick chart? aviat72 Version 7 Beta General Questions & Bug Reports 1 07-27-2010 04:10 PM
Bars.FirstBarOfSession doesn't work with Renko bars gregid Version 7 Beta General Questions & Bug Reports 20 05-24-2010 08:17 AM
x number bars back, based on time ctrlbrk Strategy Development 2 03-29-2009 01:31 PM


All times are GMT -6. The time now is 04:06 PM.