Learning From Cases Using Excel

Netica

Learning From Cases Using Excel

1. Create an Excel Spreadsheet

2. Add Nodes to the Net

3. Discretize or Combine States

4. Add Link Structure

5. Learn CPTs

6. Use the Resulting Bayes Net

You may already be starting with a Bayes net that has nodes with suitable names and states to match the Excel data, in which case you can go on to the next step.  If not, you will have to add nodes or change their names, as described below, or let Netica do it automatically as described further below.

Manually:  Ensure that each node's name or its title exactly matches the text in the cell at the top row of the Excel spreadsheet.  Also, the state names or titles must exactly match each of the possible entries in that column (unless the column contains numeric data).  The matches are case sensitive.

To achieve this, you may want to change the names of the nodes, or change the Excel cells, or add node titles.

Important: If the Excel names have spaces or special characters in them, they won't be able to match the node or state names (since those characters are not allowed in names), so they will have to match node or state titles.

Automatically:  A great time saver is Netica’s ability to examine the spreadsheet and add nodes to the Bayes net with properly matching node and state names.  The Bayes net may start off empty, or it may already have some nodes.  Choose Cases Learn Add Case File Nodes, and from the open-file dialog box presented, choose the Excel file with the spreadsheet.  After the nodes are added, you may want to re-arrange their position, or delete ones you aren’t interested in.  Nodes for numeric data will be added as = 4 && typeof(BSPSPopupOnMouseOver) == 'function') BSPSPopupOnMouseOver(event);" class="BSSCPopup" onclick="BSSCPopup('X_PU_discrete_node.htm');return false;">discrete nodes, which you probably want to convert to = 4 && typeof(BSPSPopupOnMouseOver) == 'function') BSPSPopupOnMouseOver(event);" class="BSSCPopup" onclick="BSSCPopup('X_PU_continuous.htm');return false;">continuous nodes, and the next step describes an automatic way to easily do that.

Extremely Slow:  If Excel is running, and has open the same file that you are trying to work with in Netica, the operations in Netica will be extremely slow, so close the file in Excel first.

Prev step <<  >> Next step