I'm new to LSTMs, and I'm trying to do a basic timeseries prediction using stock prices. However, I'm a bit confused as to how the LSTM is supposed to remember outputs from previous timesteps when it has a many to one shape.
For example, let's say we're at timestep
n, and the following timeseries is part of my input:
[[100, 10], [300, 30], [200, 20]]
And it maps to some output, let's say
Great. But let's say at timestep
n - 1, when the input was just
[[100, 10], [300, 30]], the output was
0. How will the LSTM know this?
Should I include the same data at different timesteps (using something like zero padding) with the corresponding output? Or am I totally misunderstanding something about how LSTMs work?