How do hidden markov models (HMMs) handle spatial data? I've seen papers where they divide the spatial area up into a grid and then model the order of the markov chain from left to right, down a row, then left to right again. This seems like its not leveraging all the information. In a time series, time goes forward or backward, but in space, you can go left to right, up and down. How do hidden markov models for spatial data account for this? Is there a better way to model spatial a latent variable?