<?xml version="1.0" ?>
<dsscheme xmlns="http://tempuri.org/ModelDescSchema.xsd" xmlns:xs="http://www.w3.org/2001/XMLSchema-instance">
<name>Play Golf</name>
<author>Blaz Zupan</author>
<date>March, 2002</date>
<description>A single model from famous Ross Quinlan's data set,
used as an example of a simple Decision Support Schema</description>

<variables>
  <variable>
    <id>forecast</id>
    <name>Forecast</name>
    <description>Forecast for next Saturday</description>
    <type>categorical</type>
    <values>sunny;overcast;rainy</values>
    <inputtype>pulldown</inputtype>
    <default>sunny</default>
  </variable>
  <variable>
    <id>temp</id>
    <name>Temperature</name>
    <description>Predicted Temperature for next Saturday</description>
    <type>numerical</type>
    <inputtype>numerical</inputtype>
    <min>30</min>
    <max>150</max>
    <default>70</default>
  </variable>
  <variable>
    <id>humidity</id>
    <name>Humidity</name>
    <description>Predicted Humidity</description>
    <type>categorical</type>
    <values>low;high</values>
    <inputtype>checkbox</inputtype>
    <checkboxchecked>low</checkboxchecked>
    <checkboxlabel>Dry weather on Saturday</checkboxlabel>
    <default>low</default>
  </variable>
  <variable>
    <id>wind</id>
    <name>Windy</name>
    <description>Is wind going to blow on next Saturday?</description>
    <type>categorical</type>
    <values>no;yes</values>
    <inputtype>checkbox</inputtype>
    <checkboxchecked>no</checkboxchecked>
    <checkboxlabel>Any wind on Saturday?</checkboxlabel>
    <default>no</default>
  </variable>

</variables>

<pages>
  <page title="Forecast for next Saturday">forecast</page>
  <page title="Meteorological factors">temp;humidity;wind</page>
</pages>

<transformations>
  <variable>
    <id>t</id>
    <name>Temperature</name>
    <categorize>
      <from>temp</from>
      <cutoffs>80</cutoffs>
    </categorize>
  </variable>
  
  <variable>
    <id>heat</id>
    <name>Heat Index</name>
    <map>
      <from>t;humidity</from>
      <mapping>0.1;0.5;0.6;0.9</mapping>
    </map>
  </variable>

  <variable>
    <id>heat_low</id>
    <hide>no</hide>
    <map>
      <from>t;humidity</from>
      <mapping>0.05;0.47;0.55;0.87</mapping>
    </map>
  </variable>

  <variable>
    <id>heat_high</id>
    <hide>no</hide>
    <map>
      <from>t;humidity</from>
      <mapping>0.13;0.54;0.67;0.92</mapping>
    </map>
  </variable>

</transformations>


<models>
  <model>
    <name>Naive Bayesian Model</name>
    <variables>forecast;t;humidity;wind</variables>
    <outcome>Probability of favorable weather to play golf</outcome>
    <naivebayes>
      <class>0.6,0.4</class>
      <contingency>
         <conditional attribute="forecast">0.6,0.4;0.5,0.5;0.66,0.34</conditional>
         <conditional attribute="t">0.625,0.375;0.5,0.5</conditional>
         <conditional attribute="humidity">0.25,0.75;0.83,0.17</conditional>
         <conditional attribute="wind">0.5,0.5;0.75,0.25</conditional>
      </contingency>
    </naivebayes>
  </model>
  
  <model>
    <name>Heat Index Model</name>
    <outcome>Relative Heat Index</outcome>
    <usevariable>
      <probability>heat</probability>
      <confidenceintervals>
        <lower>heat_low</lower>
        <upper>heat_high</upper>
      </confidenceintervals>
    </usevariable>
  </model>
</models>

</dsscheme>

