You can compute the closing stock price for a day, given the opening stock price for that day, and previous some d days’ data. Your predictor would have a latency of d days. Now, create a predictor called StockPredictor, which will contain all the logic to predict the stock price for a given company during a given day. Here's one way to do it. On one chart, keep track of the closing prices of a particular stock. On that same chart, begin a running total of trading volume - adding each day's volume to the total if the stock price goes up, subtracting it if the price goes down. That's the on-balance volume line, which you then can compare to the price line. But where they open is hard to predict with any accuracy and depends on several factors. When the regular market opens, the supply of stock available for trading is much greater than during extended hours, and prices move freely as opposed to in limited ways, as required during extended hours trading.