I have been trying to create a Transition Matrix using the data from 2000 entities over 40 observations (Years). I have ranked the data into percentiles, for example the highest value entity in a given year being in percentile 1 and the lowest value entity in 0.01. I want to see the transition probability of an entity in say percentile state 0.99 to transition to any other state X such as 0.98.
After that I used this code in R from the 'markovchain' package
FITTED_DATA <- markovchainFit(data=Entity_DATA[,2:41],name="DATA_FITTED")
There are 41 columns with the first indicating the entity ID and the following columns representing the observed years. I get a DTMC object with a 100x100 transition matrix with each row summed up equal to 1. Yet some transitions are 0.
I did the same thing with the data ranked in deciles not percentiles (from 0.1 to 1) and get no zeroes in the transition matrix, but I fear I give up a considerable deal of accuracy doing it this way. This way I end up with a 10x10 transition matrix.
Is the reason I get zeroes in the transition matrix when I use percentile ranked data, because some transitions are not in the data i.e. the transition from say 0.98 to 0.97?
Is there a better way to come up with a sensible transition matrix? I appreciate any kind of help or hints one can give me.