NexusFi: Find Your Edge


Home Menu

 





Renko backtesting open/close errors


Discussion in NinjaTrader

Updated
      Top Posters
    1. looks_one Quick Summary with 1 posts (0 thanks)
    2. looks_two Zananas with 1 posts (0 thanks)
    3. looks_3 RJay with 1 posts (0 thanks)
    4. looks_4 ShatteredX with 1 posts (0 thanks)
    1. trending_up 1,544 views
    2. thumb_up 0 thanks given
    3. group 3 followers
    1. forum 3 posts
    2. attach_file 1 attachments




 
Search this Thread

Renko backtesting open/close errors

  #1 (permalink)
Zananas
Paris France
 
Posts: 7 since Sep 2018
Thanks Given: 4
Thanks Received: 1

Hi everyone !

I'm actually backtesting a strategy on GBPUSD using a Renko based charts.
Unfortunately I'm having some issue concerning exact opening/closing price position.

For exemple my long strategy is simply based on a direction change between two following

Renko bars, here's my script :
if (Open[0] < Close[0])
&& (Open[1] > Close[1])
{
EnterLong(Convert.ToInt32(DefaultQuantity), @"Long");
}

Here's a snapshot for illustration in attachment.

On renko #1 we notice a open > close, and on renko #2 a open < close, so my entry condition is triggered as soon as renko #2 is closed.
The issue remain here : opening position price is the open of renko #3 (red triangle) instead of closing of renko #2 (green triangle).
Hence my strategy tester remain on false price entry.

NB : obviously this issue ain't encountered on candlestick chart, as close from previous bar equals open of following. But renko chart are constructed totally different.

How NinjaTrader could to manage this error ? Is there some code to implement in the strategy script to solve it ?

Thanks for your help

Attached Thumbnails
Click image for larger version

Name:	GBPUSD (140 Renko)_cropped.png
Views:	164
Size:	2.8 KB
ID:	255112  
Reply With Quote

Can you help answer these questions
from other members on NexusFi?
New Micros: Ultra 10-Year & Ultra T-Bond -- Live Now
Treasury Notes and Bonds
Exit Strategy
NinjaTrader
The space time continuum and the dynamics of a financial …
Emini and Emicro Index
NT7 Indicator Script Troubleshooting - Camarilla Pivots
NinjaTrader
ZombieSqueeze
Platforms and Indicators
 
Best Threads (Most Thanked)
in the last 7 days on NexusFi
Get funded firms 2023/2024 - Any recommendations or word …
61 thanks
Funded Trader platforms
39 thanks
NexusFi site changelog and issues/problem reporting
26 thanks
Battlestations: Show us your trading desks!
26 thanks
The Program
18 thanks
  #3 (permalink)
 ShatteredX 
Houston, TX
 
Experience: Intermediate
Platform: Python
Trading: NQ
Posts: 97 since Apr 2016
Thanks Given: 133
Thanks Received: 96


Hi @Zananas

My personal opinion: Switch to BetterRenko bars. They backtest accurately (Open[0] equals Close[1]).

Reply With Quote
  #4 (permalink)
 
RJay's Avatar
 RJay 
Hartford, CT. USA
 
Experience: Intermediate
Platform: NinjaTrader
Broker: AMP/CQG, Kinetick
Trading: RTY
Posts: 682 since Jun 2009
Thanks Given: 756
Thanks Received: 787

Read my post here.


Reply With Quote




Last Updated on September 17, 2018


© 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