# Understand transition graph

#### NicKlick

##### New Member
You may think that transition graphs are pretty straight-forward, although I'm confused. I have a matrix abcd

Code:
#in R
library(diagram)

abcd <- matrix(c("a", "b", "c", "d"), nrow = 2, byrow = TRUE)
abcd

ab <- c("A","B")
row.names(abcd) <- ab; colnames(abcd) <- ab
plotmat(abcd, pos = c(1,1),
lwd = 1, box.lwd = 2,
cex.txt = 0.8,
box.cex = 1.5,
box.size = 0.1,
box.type = "circle",
box.prop = 0.5,
box.col = "white",
box.lcol = "black",
arr.col = "black",
arr.type = "simple",
arr.length=.3,
arr.width=.2,
self.cex = .6,
self.shifty = -.01,
self.shiftx = .16)
If the Markov chain have two states, 0 & 1 then a is the transition from 0 -> 0, b is the transition from 0 -> 1, c is the transition from 1->0 and finally d is the transition from 1 -> 1. Although when I use the plotmat-function, it's displaying b as the transition from 1 -> 0 and c as the transition from 0 -> 1. I've seen this in other examples to:

https://thescipub.com/pdf/10.3844/jmssp.2013.149.154.pdf

Have I misunderstood? In that case, should I swap places on b and c so the sum of each column equals 1 instead of each row.