I'm interested in using a discrete-time non-homogeneous Markov Model for one of my studies. The data I am using has Hierarchical clustering (ex. patients within hospitals). I was wondering if anyone knows how to account for clustering in such a model. If yes, would you be able to provide some resources or sample codes. I am new to R and Markov Models so will appreciate any help I can get.
Thank you!