Exemplo n.º 1
0
        public static DataSetSpecification createIrisDataSetSpec()
        {
            DataSetSpecification dss = new DataSetSpecification();

            dss.defineNumericAttribute("sepal_length");
            dss.defineNumericAttribute("sepal_width");
            dss.defineNumericAttribute("petal_length");
            dss.defineNumericAttribute("petal_width");
            dss.defineStringAttribute("plant_category", new string[] { "setosa", "versicolor", "virginica" });
            return(dss);
        }
Exemplo n.º 2
0
        public static DataSetSpecification createAnimalDataSetSpec()
        {
            DataSetSpecification dss = new DataSetSpecification();

            for (int i = 1; i <= 20; ++i)
            {
                dss.defineNumericAttribute(string.Format("feature_{0}", i));
            }
            dss.defineStringAttribute("animal_name", new string[] { "GIRAFFE", "HIPPO", "LION" });
            return(dss);
        }
Exemplo n.º 3
0
        public static DataSetSpecification createRestaurantDataSetSpec()
        {
            DataSetSpecification dss = new DataSetSpecification();

            dss.defineStringAttribute("alternate", Util.YesNo());
            dss.defineStringAttribute("bar", Util.YesNo());
            dss.defineStringAttribute("fri/sat", Util.YesNo());
            dss.defineStringAttribute("hungry", Util.YesNo());
            dss.defineStringAttribute("patrons", new string[] { "None", "Some", "Full" });
            dss.defineStringAttribute("price", new string[] { "$", "$$", "$$$" });
            dss.defineStringAttribute("raining", Util.YesNo());
            dss.defineStringAttribute("reservation", Util.YesNo());
            dss.defineStringAttribute("type", new string[] { "French", "Italian", "Thai", "Burger" });
            dss.defineStringAttribute("wait_estimate", new string[] { "0-10", "10-30", "30-60", ">60" });
            dss.defineStringAttribute("will_wait", Util.YesNo());
            // last attribute is the target attribute unless the target is explicitly reset with dss.setTarget(name)

            return(dss);
        }