Changeset 137 for prdatasets/iris.m


Ignore:
Timestamp:
12/18/19 15:46:35 (5 years ago)
Author:
bduin
Message:
 
Location:
prdatasets
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • prdatasets

    • Property svn:ignore
      •  

        old new  
        33*.data
        44*.asv
         5data
  • prdatasets/iris.m

    r132 r137  
    55% Iris plants dataset by R.A.Fisher, 150 objects, 4 features, 3
    66% classes.
    7 function x = iris;
    87
    9 prdatasets(mfilename,1,'http://prtools.tudelft.nl/prdatasets/iris.dat');
    10 user.desc = 'Iris Plant database from UCI. A classic dataset in the pattern recognition literature.  The original dataset is a multiclass classification problem, introduced by R.A. Fisher, The use of multiple measurements in taxonomic problems. Ann Eugenics, 7:179--188, 1936.';
    11 user.link = 'ftp://ftp.ics.uci.edu/pub/machine-learning-databases/iris/';
    12 cl = {'Iris-setosa' 'Iris-versicolor' 'Iris-virginica'};
    13 fl = {'sepal length' 'sepal width' 'petal length' 'petal width'};
     8function a = iris
    149
    15 % the fuzzy toolbox has a iris.dat file too, avoid it
    16 pp = fileparts(which(mfilename));
    17 a = load(fullfile(pp,'iris.dat'));
    18 x = pr_dataset(a(:,1:(end-1)), cl(a(:,end)));
    19 x = setfeatlab(x,fl);
    20 x = setuser(x,user);
    21 x = setname(x,'Iris');
     10a = pr_loadmatfile;
     11if isempty(a)
     12  opt.labfeat    = 5;
     13  opt.featnames  = {'sepal length' 'sepal width' 'petal length' 'petal width'};
     14  opt.classnames = {'Iris-setosa' 'Iris-versicolor' 'Iris-virginica'};
     15  opt.desc       = 'Iris Plant database from UCI. A classic dataset in the pattern recognition literature.  The original dataset is a multiclass classification problem, introduced by R.A. Fisher, The use of multiple measurements in taxonomic problems. Ann Eugenics, 7:179--188, 1936.';
     16  opt.link       = 'ftp://ftp.ics.uci.edu/pub/machine-learning-databases/iris/';
     17  opt.dsetname   = 'Iris';
     18  a = pr_download('http://prtools.tudelft.nl/prdatasets/iris.dat',[],opt);
     19end
    2220
    2321return
Note: See TracChangeset for help on using the changeset viewer.