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, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0,
0}, {0, 0, 0, 0, 0, 0, 0.2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
0}, {0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1,
0}, {0, 0, 0, 0, 0, 0, 0, 0, 0.9, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}};
And I converted this to DiscreteMarkovProcess
mark = DiscreteMarkovProcess[1, tmat];
graph = Graph[mark,EdgeLabels -> {DirectedEdge[i_, j_] :>
MarkovProcessProperties[mark, "TransitionMatrix"][[i, j]]}];
sp = FindShortestPath[graph, 1, 10]
HighlightGraph[graph, sp]
So is there a simple way to find the shortest path by edge weight, like the path is selected by highest transition probability? For example for 1-> 3, it will go via 14 instead the 2.
Also can we hide or remove the disjointed states like 13, 15 ?
Thanks!