You are missing trading opportunities:
- Free trading apps
- Over 8,000 signals for copying
- Economic news for exploring financial markets
Registration
Log in
You agree to website policy and terms of use
If you do not have an account, please register
I don't trade futures and my knowledge is lacking in that area, but I am pretty confidant that it is not the DOM. As far as I know, the Depth-of-Market or the Order Book, is something completely different and represents the open liquidity available at the time, based on the number of open buy and sell orders. MetaTrader does offer that information as a separate data structure to that of the tick data, but not as historical data, as @Alain Verleyen pointed out.
As a follow-up I call your attention to the following ...
But isn't the DOM historical data the bid, ask, last, volume per each tick? This is the information shown in the Depth of Market in live trading.
Or am I misunderstanding your point?
That's tick data, also sometimes called Time & Sales. Tick data are 'raw' data, from them you can build Time & Sales. These data are directly available in the Tester.
DOM is something else, the Depth of Market is showing the "depth" of offer/demand prices and volumes.
Understood, I'll do further reading on theoretical concepts. I appreciate the help.
2 questions:
1. Given all the discussion, I would like to confirm that the backtest (using only tick data) takes into account tick values, bid, ask, last, and volume to simulate trades. Is that correct?
2. Incorporating DOM data into the backtest would likely make the results more realistic. However, do you know if the difference is significant when I'm already using tick data in a limit price based strategy (e.g., ATM)? Or is this too broad of a question to answer definitively?
That's tick data, also sometimes called Time & Sales. Tick data are 'raw' data, from them you can build Time & Sales. These data are directly available in the Tester.
DOM is something else, the Depth of Market is showing the "depth" of offer/demand prices and volumes.
Understood. Thank you for your time!
As a follow-up I call your attention to the following ...
Understood, I'll do further reading on theoretical concepts. I appreciate the help.
2 questions:
1. Given all the discussion, I would like to confirm that the backtest (using only tick data) takes into account tick values, bid, ask, last, and volume to simulate trades. Is that correct?
2. Incorporating DOM data into the backtest would likely make the results more realistic. However, do you know if the difference is significant when I'm already using tick data in a limit price based strategy (e.g., ATM)? Or is this too broad of a question to answer definitively?
1. Yes, but that also depends on your EA code. If your program is flawed, you may get some strange results and then think that it is the tester's fault, when in fact it is a coding problem. Be aware of that.
2.a. By ATM are you referring to Ninjatrader's Advanced Trade Management? If so, then that is just a naming gimmick. That does not really exist. It is just general trade management concepts which they have grouped and automated and given a fancy name. It definitely is not a strategy. In MetaTrader, those concepts have to programmed as per your trading rules. They are not pre-automated, except for the Stop-Loss and Take-Profit. All the other concepts, such as break-even, trailing-stops, chasing, reversals, etc. have to be coded yourself. There is no generalisation. They change depending on your strategy rules and the trade, risk and money management rules you want to apply.
2.b. I lack experience with Futures, but I doubt incorporating the real DOM history, will have any impact if you don't actually trade against the order book in your strategy. The fact that you were confusing the Tick Data with the DOM, tells me that your strategy does not trade the order book directly at all. So, I believe, there should be no impact in the back-tests without the historical DOM.
I appreciate the help.
Let me explain my strategy's components in more detail so we can reach a clear and sustainable conclusion.
First, you're right—my strategy does not use any order book (DOM) information. I simply place limit orders to enter or exit based on price, and for that, tick data is sufficient. The conditions I use for placing limit orders are not tied to DOM data either; only to price.
My main concern is whether the backtester is accounting for all the necessary information. For instance, I wouldn't be able to sell a contract at 20,000 if there's no buyer in the historical data. When a backtester only uses tick values, it might fill orders unrealistically. However, when bid, ask, and volume are considered, the results are more realistic because it would show that I couldn’t sell the contract at 20,000 if there were no matching buyers. I noticed this effect clearly in NinjaTrader's market replay.
After all this discussion, my concern boils down to how the backtester processes the data to produce realistic results. Having bid, ask, last price, and volume per tick is essential for this process, and as you've mentioned—and as I’ve seen in the documentation—the backtester does include this. However, wouldn’t incorporating DOM data make the results even more realistic? I am still assimilating the DOM concept.
1. Yes, but that also depends on your EA code. If your program is flawed, you may get some strange results and then think that it is the tester's fault, when in fact it is a coding problem. Be aware of that.
2.a. By ATM are you referring to Ninjatrader's Advanced Trade Management? If so, then that is just a naming gimmick. That does not really exist. It is just general trade management concepts which they have grouped and automated and given a fancy name. It definitely is not a strategy. In MetaTrader, those concepts have to programmed as per your strategy rules. They are not pre-automated, except for the Stop-Loss and Take-Profit. All the other concepts, such as trailing-stops, chasing, reversals, have to be coded yourself.
2.b. I lack experience with Futures, but I doubt incorporating the real DOM history, will have any impact if you don't actually trade against the order book in your strategy. The fact that you were confusing the Tick Data with the DOM, tells me that your strategy does not trade the order book directly at all. So, I believe, there should be no impact in the back-tests without the historical DOM.
This means that the tick data I have provides only the best price at which a contract could be bought or sold at each tick, along with the corresponding volume. This implies that I do not have access to all the bids and asks made, which represent the DOM and reflect the deepest level of supply and demand available.
Is my conclusion correct?
That's tick data, also sometimes called Time & Sales. Tick data are 'raw' data, from them you can build Time & Sales. These data are directly available in the Tester.
DOM is something else, the Depth of Market is showing the "depth" of offer/demand prices and volumes.
3195512 #: I appreciate the help. Let me explain my strategy's components in more detail so we can reach a clear and sustainable conclusion.
First, you're right—my strategy does not use any order book (DOM) information. I simply place limit orders to enter or exit based on price, and for that, tick data is sufficient. The conditions I use for placing limit orders are not tied to DOM data either; only to price.
My main concern is whether the backtester is accounting for all the necessary information. For instance, I wouldn't be able to sell a contract at 20,000 if there's no buyer in the historical data. When a backtester only uses tick values, it might fill orders unrealistically. However, when bid, ask, and volume are considered, the results are more realistic because it would show that I couldn’t sell the contract at 20,000 if there were no matching buyers. I noticed this effect clearly in NinjaTrader's market replay.
After all this discussion, my concern boils down to how the backtester processes the data to produce realistic results. Having bid, ask, last price, and volume per tick is essential for this process, and as you've mentioned—and as I’ve seen in the documentation—the backtester does include this. However, wouldn’t incorporating DOM data make the results even more realistic? I am still assimilating the DOM concept.
Since I lack the experience with Futures, what I am about say could be incorrect, but ... if your strategy is so "delicate" that the lack of DOM history could through your results off so much, then it is NOT a good strategy.
It would mean that the strategy is not robust enough to handle different market conditions and any little "glitch" would through it off and cause great losses.
So, as long as the back-tests can be 80-95% accurate compared to the live trading, I would consider it irrelevant if the DOM history is used or not.
What is important, is that in the back-testing, all the logic is executed accurately and correctly according to your strategy and trading rules, and that in general terms, it is sufficiently profitable, and the metrics, such profit-factor, recovery-factor, draw-down, MAE, MFE, etc. are favourable in your analysis.
After that, apply the EA on a live demo account, and compare the results. If they are within the margin of error compared to back testing, then move forward and don't focus so much on having the "perfect" back-testing conditions.
If the back-test and live trading are very different, then blame the strategy or the code. The back-testing abilities will be the least of your problems.
This means that the tick data I have provides only the best price at which a contract could be bought or sold at each tick, along with the corresponding volume. This implies that I do not have access to all the bids and asks made, which represent the DOM and reflect the deepest level of supply and demand available.
Is my conclusion correct?
I may be misunderstanding your issue, but the tick data also provides the ask and bid quotes too, as it progresses.
However, the "proof is in the pudim"—why not just code a simple EA (or use and existing EA) , with a very simple strategy and run it o demo account and run a back-test for the same period and compare them.
Sometimes, the best way to learn, is to simply DO instead of asking.
Also, here is a question for you, that may help explain to us your line of thinking—why did you decide to make the change from Ninjatrader to MetaTrader?
Was it because of the back-testing or was it for another reason?
If the back-testing on NT was sufficiently accurate and reliable, then there should be no trouble in that aspect with MetaTrader. If however, you are switching because your back-testing with NT was not sufficiently the same as your live trading, then it is most likely a problem with the strategy or code-logic, and not with the back-testing.