Mathematica Stack Exchange is a question and answer site for users of Mathematica. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I apologize for my heaviness as I am a Mathematica novice. Is there a kind soul who can tell me how to draw diagrams like those shown on page 158, 160 and 161 of this document.Chaine de Markov

I oversee several plotting examples unsuccessfully.

share|improve this question

Here's an answer straight from the documentation for DiscreteMarkovProcess

Graph[DiscreteMarkovProcess[3, {{1/2, 1/2, 0, 0}, {1/2, 1/2, 0, 0}, 
    {1/4, 1/4, 1/4, 1/4}, {0, 0, 0, 1}}]]

Mathematica graphics

which graphs a fourth order Markov chain with the specified transition matrix and initial state 3. The colors occur because some of the states (1 and 2) are transient and some are absorbing (in this case, state 4). You can customize the appearance of the graph by looking at the help file for Graph.

share|improve this answer
Please note that this solution is available only starting with version 9. (Such a graph can be drawn with earlier versions of Mathematica but it takes a lot of fiddling.) – whuber Mar 26 '13 at 15:02

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.