Go Back   NinjaTrader Support Forum > Application Technical Support > Strategy Analyzer

Strategy Analyzer Support for automated system backtesting and optimization using the NinjaTrader Strategy Analyzer.

Reply
 
Thread Tools Display Modes
Old 02-12-2013, 02:35 PM   #1
sburtt
Senior Member
 
Join Date: Jul 2012
Posts: 269
Thanks: 36
Thanked 5 times in 5 posts
Default Changing the default currency

Hi,

is there a way to change the default currency used to indicate the account value and p&l? I am asking this because I am using Interactive Brokers to trade Forex. I am UK based, my base currency is GBP, however I noticed that the GBP amount indicated as p&l in my strategies is actually incorrect. This is very wierd (and misleading). I might be doing something wrong and I was wondering how If there is a way to define the currency in which p&l is expressed. Please see attached to understand what I mean. In the attached I've been trading 50k EURJPY, in the attached (points_amount) you can see the cumulative profit in JPY amount 112,850 that is approximately 750 GBP or 1170 USD, but far from what the total net profit of 603$ stated by the strategy says. What is that 603 based on? any guess? Thanks for your help, John
Attached Images
File Type: png currency_amount.png (26.4 KB, 8 views)
File Type: png points_amount.png (28.4 KB, 4 views)
sburtt is offline  
Reply With Quote
Old 02-12-2013, 02:55 PM   #2
NinjaTrader_Matthew
NinjaTrader Customer Service
 
NinjaTrader_Matthew's Avatar
 
Join Date: Apr 2010
Location: Denver, CO, USA
Posts: 5,722
Thanks: 189
Thanked 778 times in 744 posts
Default

The PnL displayed will be based off your PC region settings.

Can you clarify what instruments you were trading? Were these USD based pairs such as the EURUSD? Or was it a non-USD pair like the GBPJPY?

If you check on the Executions tab of the Control Center there will be a "rate" column which should tell us the conversion rate applied. Is this a factor of 1, or another number?
NinjaTrader_Matthew is offline  
Reply With Quote
Old 02-12-2013, 03:00 PM   #3
sburtt
Senior Member
 
Join Date: Jul 2012
Posts: 269
Thanks: 36
Thanked 5 times in 5 posts
Default

Matt, thx for the promp reply, as stated in the thread it's EURJPY, %p&l is correct, same as the point count, but $amt is incorrect, check attached, i'm based in london, uk
Attached Images
File Type: png 2013-02-12_2059.png (29.8 KB, 7 views)
sburtt is offline  
Reply With Quote
Old 02-12-2013, 03:04 PM   #4
sburtt
Senior Member
 
Join Date: Jul 2012
Posts: 269
Thanks: 36
Thanked 5 times in 5 posts
Default

as you see from attached the rate is a little wierd, how can i change that?
Attached Images
File Type: png rate.png (17.8 KB, 12 views)
sburtt is offline  
Reply With Quote
Old 02-12-2013, 03:09 PM   #5
NinjaTrader_Matthew
NinjaTrader Customer Service
 
NinjaTrader_Matthew's Avatar
 
Join Date: Apr 2010
Location: Denver, CO, USA
Posts: 5,722
Thanks: 189
Thanked 778 times in 744 posts
Default

Thanks for the confirmation. This is a result of not having the USD based pair streaming to NinjaTrader when these trades were executed, and as a result, the conversion is not correct, resulting in incorrect PnL.

There is no way to change the already calculated rate, but you can prevent this from happening moving forward by opening a market analyzer and ensuring you have streaming data for each cross pair you plan on trading.
NinjaTrader_Matthew is offline  
Reply With Quote
Old 02-12-2013, 03:15 PM   #6
sburtt
Senior Member
 
Join Date: Jul 2012
Posts: 269
Thanks: 36
Thanked 5 times in 5 posts
Default

you mean that by keeping the market analyzer open I record tick data? I was keeping charts open for this purpose, isn't this the same?
sburtt is offline  
Reply With Quote
Old 02-12-2013, 03:18 PM   #7
NinjaTrader_Matthew
NinjaTrader Customer Service
 
NinjaTrader_Matthew's Avatar
 
Join Date: Apr 2010
Location: Denver, CO, USA
Posts: 5,722
Thanks: 189
Thanked 778 times in 744 posts
Default

It should be the same, but the only reason the conversion rate wouldn't match is because we didn't have the correct data at that time. It's hard to say what was happening with your charts at that time. To ensure that you have the correct data, I'd recommend throwing all the relevant symbols in the market analyzer and just minimizing that.
NinjaTrader_Matthew is offline  
Reply With Quote
Old 02-12-2013, 03:25 PM   #8
sburtt
Senior Member
 
Join Date: Jul 2012
Posts: 269
Thanks: 36
Thanked 5 times in 5 posts
Default

understood. just out of curiosity:
1.how would this work for back-testing? I mean what rate would it use?
2.is there no what I can change that rate on the execution page?
3.most importantly, is the Cumulative profit %/points a more reliable filed to look at, when back testing different currency pairs?
sburtt is offline  
Reply With Quote
Old 02-12-2013, 03:38 PM   #9
NinjaTrader_Matthew
NinjaTrader Customer Service
 
NinjaTrader_Matthew's Avatar
 
Join Date: Apr 2010
Location: Denver, CO, USA
Posts: 5,722
Thanks: 189
Thanked 778 times in 744 posts
Default

In backtesting, it will always use a rate of 1 and the results are going to be the PnL base currency. In terms of the EURJPY, the PnL will be in Yens, but we will incorrectly show a $

You cannot change the conversion rate on any previous executions unfortunately.

Unfortunately percent wouldn't be more dependable here as the calculation as it still looks at profit $

PRODUCT(1 + profit / entry price) of all trades - 1

I'd say points would be more dependable.

We're looking to improve this limitation in the next major release of NinjaTrader.
NinjaTrader_Matthew is offline  
Reply With Quote
Old 02-12-2013, 03:43 PM   #10
sburtt
Senior Member
 
Join Date: Jul 2012
Posts: 269
Thanks: 36
Thanked 5 times in 5 posts
Default

thanks Matt, this explanation really helps
sburtt is offline  
Reply With Quote
The following user says thank you to sburtt for this post:
Old 02-12-2013, 04:32 PM   #11
sburtt
Senior Member
 
Join Date: Jul 2012
Posts: 269
Thanks: 36
Thanked 5 times in 5 posts
Default

Matt, actually i've double checked and the rate on the execution page (0.0107) is the inverse of USDJPY, as if the system reports the JPY profit/loss back to USD. But why is this reporting USD when I'm UK based? shouldn't this covert using GBPJPY?

assuming it converts to USD, anyhow the conversion is wrong, it's massively off. Now I am checkin my live p&l and also this is different. EURJPY is 125.75, i"m short from 125.30 in 50k Eur and the p&l stated in ninja is 132, this is clearly wrong, loss is 22,500 JPY that if you convert in USD 22,500/94 = aprox 240$ whilst in gbp you owuld have 22,500/146.5 = 153, far from 132 on a 50k notional basis, what could the issue be? I've market analyser open

whould it be best to report everything back in usd? how can i do this?
sburtt is offline  
Reply With Quote
Old 02-12-2013, 05:15 PM   #12
sburtt
Senior Member
 
Join Date: Jul 2012
Posts: 269
Thanks: 36
Thanked 5 times in 5 posts
Default

Matt to make it even more clear, have a look at the attached. On the summary it states that the net profit is 350$+ whilst the sum of single trades in excel report a negative p&l. How would you read this? it doesn't look very reliable when running different strategies on different currency pairs.. is any of the stats provided by ninja reliable in your experience when looking at combined results? do you get my concern?
Attached Images
File Type: jpg excel_calculus_vs._Account_Summary.jpg (169.1 KB, 5 views)
sburtt is offline  
Reply With Quote
Old 02-13-2013, 09:27 AM   #13
NinjaTrader_Matthew
NinjaTrader Customer Service
 
NinjaTrader_Matthew's Avatar
 
Join Date: Apr 2010
Location: Denver, CO, USA
Posts: 5,722
Thanks: 189
Thanked 778 times in 744 posts
Default

Can you please send me your database file so I can look into this further.

You can do this by going to the Control Center-> Help-> Mail to Support-> check "Database file"

Please reference the following thread in the body of the email: http://www.ninjatrader.com/support/f...ad.php?t=55842
NinjaTrader_Matthew is offline  
Reply With Quote
Old 02-17-2013, 08:49 AM   #14
sburtt
Senior Member
 
Join Date: Jul 2012
Posts: 269
Thanks: 36
Thanked 5 times in 5 posts
Default

Matt, I've sent you the mail as requested. Just to make it clear what I am worried about:

have a look at the attached file. the strategy runs on eur/jpy, hence the points are in jpy pips, if you convert the amount of cumulative profit to gbp (dividing 138,350 jpy/ 145), it's approximately -950, very distant from the -739.68 total net profit indicated by ninjatrader. this amount can't be $ or eur, as this would be even higher than gbp amount.

This matter is frustrating, as all my back testing and statistics are probably incorrect.

please could you advise if there is something i can do for this.thanks
Attached Images
File Type: png help.png (122.8 KB, 9 views)
sburtt is offline  
Reply With Quote
Old 02-18-2013, 08:12 AM   #15
NinjaTrader_Matthew
NinjaTrader Customer Service
 
NinjaTrader_Matthew's Avatar
 
Join Date: Apr 2010
Location: Denver, CO, USA
Posts: 5,722
Thanks: 189
Thanked 778 times in 744 posts
Default

Did you get my email in response to your database? I need to know if you received the information that was sent as a lot of what you're asking here pertains to that.

1) The PnL would not be converted to GBP in this case.
2) The conversion rate is real-time and dynamic to the current market price. Using a single value to covert from would not give you the exact calculations.

2a) This is the case for real-time executions. In backtesting, the values will always be in JPY as there is no conversion done for non-USD pairs.
2b) As a result of this, you can trust your backtest results are calculated correctly in JPY and you can then manually cross to GBP if needed.
NinjaTrader_Matthew 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
Currency view as default kucharek Strategy Analyzer 1 02-21-2012 02:07 PM
changing default EMA values ionaz Indicator Development 2 10-02-2011 02:24 AM
Changing simulator open position local currency to USD laurus12 Miscellaneous Support 5 08-10-2010 03:30 PM
Default P/L currency help Lord Snooty Miscellaneous Support 2 02-02-2009 11:23 AM
Changing base currency bulegila Strategy Analyzer 11 08-19-2008 03:56 PM


All times are GMT -6. The time now is 06:13 AM.

FULL RISK DISCLOSURE: Futures trading contains substantial risk and is not for every investor. An investor could potentially lose all or more than the initial investment. Risk capital is money that can be lost without jeopardizing ones financial security or lifestyle. Only risk capital should be used for trading and only those with sufficient risk capital should consider trading. Past performance is not necessarily indicative of future results. View Full Risk Disclosure.