Total profit shown in Quant Analyzer different to that shown in MT4 report
30 replies
fourtytwo
8 years ago #114008
Hi! I’m new to Quant Analyzer, apologies if this question has a simple answer:
When I load the MT4 report (.htm) in to Quant Analyzer, Total Profit, Gross Profit, Gross Loss, they’re all out by a few cents (e.g. MT4 Gross Profit 198.79, Quant Analyzer Gross Profit 198.96). I can’t figure out why these numbers should not match up?
Thanks,
Armin
tomas262
8 years ago #131683
Can you attach results file?
fourtytwo
8 years ago #131730
Hi Tomas
What results file would you like me to attach? Will do as soon as I get back home to my computer in a few days.
Thank you!
fourtytwo
8 years ago #131829
Here are two screen grabs to illustrate my point.
From the MT4 Tester Report tab:
From Quant Analyzer:
felipebr
8 years ago #131843
Hi fourtytwo, it’s not the only problem max consecutive win and losses are also wrong… I’m really worried because Quant Analyser is already version 4 and have this such a kind of basic bug.
tomas262
8 years ago #131989
It seems the differences occur because of decimal numbers rounding. A lot of tiny differences is combined into this several cent difference. Will let Mark know about this if anything can be done
fourtytwo
8 years ago #132257
@felipebr: I hadn’t noticed that consecutive win and losses being wrong – will look at that next time.
@tomas262: Thanks for your feedback so far Tomas. Anything more on this from Mark? I’m just wondering why it needs to round numbers in any case and not just import & analyse the numbers as they are?
fourtytwo
8 years ago #132591
Hi Tomas, have you spoken to Mark about this? I was wondering why Quant Analyzer needs to round numbers at all and doesn’t just import & analyse them as they are?
tomas262
8 years ago #132719
stearno
8 years ago #132755
tomas,
Any idea when the new analyzer release will come out? It does not work with my NT7 files and cuts off hours of 13 – 24 on the data. So it is unusable… Apreciate the update.
-Stearno
Tamas
8 years ago #132758
Hello stearno,
for fast bugfix put the code below to one of your snippet.
It adds a new format type to the supported date formats.
import com.strategyquant.lib.time.DateFormats; DateFormats.getInstance().getAvailableDateFormats().add(0, "dd/MM/yyyy hh:mm:ss aa");
eg.
package com.strategyquant.extend.TradeListColumns; import com.strategyquant.lib.databank.TradeListColumn; import com.strategyquant.lib.results.SQOrder; import com.strategyquant.lib.time.SQTime; import com.strategyquant.lib.time.DateFormats; //NEW LINE ############################################ public class OpenTime extends TradeListColumn { public OpenTime() { super(); DateFormats.getInstance().getAvailableDateFormats().add(0, "dd/MM/yyyy hh:mm:ss aa"); //NEW LINE ############################################ setName("Open time"); setWidth(140); } @Override public Object getValue(SQOrder order, String plType) { return order.OpenTime; } @Override public String displayString(SQOrder order, String plType) { long openTime = (Long)getValue(order, plType); return SQTime.toString(openTime); } }
Best regards,
Tomas
stearno
8 years ago #132794
Mark Fric
8 years ago #133213
as for rounding – QA doesn’t just use the numbers that are in the report, it has to recognize them and perform several calculations on its own.
But I don’t think it is important whether the number is $ -1491.84 or $ – 1491.83.
Max consecutive wins and losses are wrong – no they aren’t, but they might be computed slightly differently. For example, the difference could be in QA considers trade with PL=0 as winning / losing / not counting.
Unlike MT4, you can see the exact formula in QuantEditor, in StatValues/ConsecutiveValues.java
Mark
StrategyQuant architect
daveM
8 years ago #133327
I have learned to be a bit skeptical of MT4 numbers.
One would think that after so many years, Metaquotes would have substantially upgraded their output.
We are actually fortunate to have an alternative evaluation software.
fourtytwo
8 years ago #133582
Sounds good to me guys, thanks!
daveM
8 years ago #133679
I just loaded an MT5 report…… there is significant differences between MT5 and Analyzer…… number of trades, net profit…… The net profit differs by 50 percent. Not a small rounding error.