Posted on July 29, 2013 @ 07:14:00 AM by Paul Meagher
Previously I discussed a simple risk management framework that involves precisely specifying the actions, events, and outcomes involved in a decision problem.
One aspect of "precisely specifying" a decision is representing the overall decision making problem in the form of a graph. We can use a pad of paper to draw lines representing possible actions, which lead to events, which lead to outcomes. Or, we can use a tool like Graphviz to construct much prettier graphs and make us feel more professional.
GraphViz was developed by AT&T Research and is considered a top-tier tool for creating/visualizing graph structures.
In today's blog, I want to give you a basic idea of how Graphviz works so you can judge for yourself whether you want to invest time into learning it.
To generate a graph using Graphviz you need to write some commands into a "dot" file that ends with the extension ".dot". The term "dot" is also used to denote one of the main Graphviz programs used to generate graphs from dot files. Also, the term "DOT" is used to refer to the command langauge you enter into your dot files.
Without further ado, here is dot file called DecisionTree.dot that depicts a decision in terms of an action, event, outcome framework for managing risk.
If I run this command from my Linux command prompt:
dot -Tpng DecisionTree.dot > DecisionTree.png
The dot interpreter will read the file and generate the graph in png format. This is what that output looks like.
As you can see, it is not difficult to go from entering commands into a dot file and generating a decent looking graph. The DOT language has much more powerful features for drawing graphs than what I am showing you here; however, in the initial stages of sketching out the actions, events, and outcomes involved in your decision problem, you may want to keep things simple and just focus on drawing out all the nodes and the lines between them.
The graph below visualizes a nitrogren application decision. Do I apply 90 lbs per acre of Nitrogren or 110 lbs? The effect of each action on the crop I want to grow is jointly determined by the amount of rainfall I'm likely to recieve over the growing season. The action forks (i.e., application amounts) lead to the event forks (i.e., rainfall amounts) which lead to the terminal outcomes (i.e., expected number of bushels).
|