I am using ITesterClient to perform historical backtests. Up till now, I have relied on the strategy's IAccount.getEquity() calls to monitor the equity. The last call during a backtest [from Strategy's onStop] reports an equity similar to the one in the [ITesterClient.createReport] strategy report's Finish Deposit field. There were minute differences, e.g. $50,572.83 vs $50,573.97, $50,473.03 vs $50,472.16, and $49,999.97 vs $49,999.52 - so I just ignored them.
However, I have just now started using ITesterReportData and discovered that its ITesterReportData.getFinishDeposit() method reports a different result than the other methods, described above. For example, in the last case, ITesterReportData.getFinishDeposit() reported $50,153.98 vs $49,999.xx.
Why is there such a difference, in particular between strategy report [as created using ITesterClient.createReport] and ITesterReportData.getFinishDeposit()? Which is right? Which one should I use? Why are they not all completely consistent?
Please advise. Thank you!
|