# Developing Markov Transition Matrix

I would like to build a transition matrix based on some tabular data given that:

• I have about 50,000 historical data points
• Data is organized in a way such as road_id, age, condition
• There are 10 condition levels (1 to 10)
• The Transition Matrix will be condition vs. condition. Roads are assumed to deteriorate based on their current condition and not on any historical data. i.e. if currently the road is in condition 5, it can either stay at 5 or go to 6. Whatever happened in the past is of no effect.
• Age is the "known" variable as in it's the only variable that is "actual" for all the data. Condition is either calculated, assumed, or observed based on video, calculations, local knowledge, etc.
• the TPM is of the following structure:

$$\begin{bmatrix} a & b & 0 & 0 & ... & 0 \\ 0 & c & d & 0 & ... & 0 \\ ... & ... & ... & ... & ... & ... \\ 0 & 0 & 0 & 0 & ... & 1 \end{bmatrix}$$

• The reason that the last Pnn = 1 is that a road can't get any worse once it reaches that stage.

Data Sample:

$$\begin{array}{lr} \text{age} & \text{condition} \\ \hline 0 & 1.18 \\ 0 & 1.18 \\ 30 & 9.87 \\ 13 & 4.97 \\ 26 & 8.30 \\ 19 & 6.50 \\ 11 & 3.82 \\ 9 & 2.68 \\ 6 & 1.49 \\ 9 & 2.68 \\ 16 & 6.22 \\ \end{array}$$

What is the correct way to calculate my Transition Matrix?

The transition matrix shall be used to:

• Estimate and forecast road conditions in the future whether as a whole or for a unique road. For example, what's the average condition of roads of type A or what's the condition of road R001 now and what will its condition be in 10 years?
• I currently use a mixed integer program to solve this but I'm toying around with probabilistic models.
• How are the "10 condition levels" related to the numerical values in the "condition" column in your data sample?
– whuber
Feb 3 '15 at 19:18
• @whuber, 0-1, 1-2, 2-3, 3-4, 4-5, 5-6, 6-7, 7-8, 8-9, 9-10 Feb 3 '15 at 19:19