The LMT model allows decoding to include never-visited locations. The LMT model is fitted to the neural data by iteratively updating a latent 1D and 2D trajectory. Orange and blue arrows and lines show latent direction (top) and position trajectory (bottom) during 17 theta cycles from a wagon-wheel session at different stages of the model-fitting (left to right). The full running trajectory is shown in light grey. The latent direction and position signals are initialized with the rat’s actual head direction and running trajectory (iteration 1) but evolve into sweep-like trajectories that cover the 2D space surrounding the maze (iteration 150).