Bayesian Belief and Decision Networks

applet home
help contents
quickstart
general help
tutorials
 

Tutorial Three: Querying a graph (Part I)

Both this tutorial and the next will use the Basic Fire Alarm Problem to demonstrate the basics of querying graphs. This tutorial will cover the rudimentary elements - making observations and performing simple queries. Below is a simplified version of the main Bayes Applet, with the Basic Fire Alarm Problem already loaded. When you load a pre-existing graph, the applet automatically enters 'Solve' mode, in which you perform queries and make observations. To modify the graph, click on the tab marked 'Create' to return to create mode. The applet below does not have a full set of controls enabled.

To make an observation about a node, right-click on it. You will see a menu entitled 'Node Options'. The first option will read 'Make Observation' and beneath it will be a list of possible domain values. Select any of these values and you will see the value you selected displayed beneath the node name. Select '<none>' to clear an observation made. In the full applet, the controls are slightly different. To make an observation, you can right-click on the node and select 'Make Observation', or select 'Make Observation' from the menu at the left hand side of the window and click on the node. When you do so, you will see a dialog box such as this one:

Select the value you want, or '<none>' to clear the observation, and click 'OK'.

There are two principal ways in which you can gain information about a node's probability. The first way is monitoring. When a node is set as monitored, information about its probability will be displayed below its name, and that information will be updated as observations are made about the probabilities of other nodes that affect it. A node which has already been observed cannot be queried, as its probabilities are known. In the example below, you can set a node to be monitored by right-clicking on it, and selecting the option 'Monitor Node'. To stop monitoring a node, right-click on it again, and select the option 'Stop Monitoring'. Monitoring is automatically stopped for a node when you observe a particular value for it. In the full version of the applet, you can also select 'Toggle Monitoring' from the menu at the left hand side of the window and click on a node to start or stop monitoring it.

The second way to gain information about a node's probability is querying. There are three different query modes for the applet: Brief, Verbose, and Prompt. The default setting is Brief mode. When you use the full version of the applet, you will be able to select the desired mode from a menu called 'Query Options'. The graph below is in Brief Query Mode. To query a node, right-click on it and select 'Query Node'. A window will open showing the node's probabilities, and it will list any observations you have made. Verbose Query Mode will be covered in the next tutorial. If the graph is in Prompt mode, each time you attempt to query a node, a dialog will open asking whether you would like a Brief or Verbose query. Also, in the full version of the applet, you will be able to select 'Query Node' from the menu at the left hand side of the window and click on a node to query it.

The conditional probability tables that are used in calculating the probabilities of each node can be viewed by right- clicking on that node, and selecting 'View Probability Table'. This will be an option on the left hand side of the window, in the full version of the applet. A window will open with information about the node's probability given values for each of its parents. This is the same information you would see if you were in 'Create' mode, and modifying the probability table.