I'm trying to understand the rationale behind using information drive bars over traditional time bars and specifically when it comes to practically feeding those in to a machine learning model to run a regression.

I was wondering, how could one feed alternative bars into a machine learning model? If we use time bars, when we run prediction, we will get a prediction on n number of time steps, but we already know our time step, whether it's a minute, hourly or daily prices.

If for example we use dollar bars instead, our sampling is at non fixed time intervals, but rather on the dollar volume traded. So we don't know what the time step is.

Therefore if we feed this into our model and then run to predict, what will the output be? I'm guessing that each 'step' will be every time a certain amount of dollar value is traded. Correct me if I'm wrong.

How then would the trader know when to enter or exit a position? Is the idea to constantly monitor the trading activity? i.e whenever the specified dollar value is traded? How would that work practically?

  • $\begingroup$ You can monitor trades and calculate the cumulative dollar amount traded. When the threshold is reached your bar is complete. $\endgroup$
    – Bob Jansen
    Jan 26, 2022 at 13:45

1 Answer 1


Q: How could one feed alternative bars into a machine learning model?

It's the same as how you would normally feed time bars. You are only changing how you sample information, but the bar will have the same structure. So for each dollar bar you still get, lets say, "High/Low/Open/Close" as four features, which could have different values from the ones sampled from a time bar, but for the machine learning model it's the same, and you will get a prediction. Now for the prediction to make sense, you have to generate new labels based on your dollar bars, which represent the future return after every $X$ amount is reached, instead of the future return after $n$ time steps.

Q: How then would the trader know when to enter or exit a position?

It's still the same as before. Once your prediction signal is strong enough, you could consider enter or exit a position. In practice, whenever a new bar is generated, your model receives new data and makes a prediction, then your trading strategy decides whether to trade on the signal. You may want to adjust your strategy though, because now your stream of signal does not have even time intervals. As the author points out, with a dollar bar you are in sync with the arrival of information, and the sampled returns have better statistical properties.


Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.