In machine learning, for a given input instances you get an output what are present at the same time. But in stock market you have to predict the next price based on previous inputs. So if you want to predict the next price (output) with machine learning, how you do it lacking new input instances (for example: high price, low price, open price, close price, volume, etc.)?
I want to use a simple example to be clear what I want to understand here.
For example :
I use high price, low price, open price and volume as inputs and close price as output. I train the algorithm with input-output samples. Then I want to predict an output (close price). But the problem is that inputs and output appears together so this way I can`t predict the next price because it has already appeared with inputs. So how is that, how do they apply?