ECOCPAK v0.9
fn_uci_iris.hpp
Go to the documentation of this file.
00001 // Copyright (C) 2011 the authors listed below
00002 // http://ecocpak.sourceforge.net
00003 // 
00004 // Authors:
00005 // - Dimitrios Bouzas (bouzas at ieee dot org)
00006 // - Nikolaos Arvanitopoulos (niarvani at ieee dot org)
00007 // - Anastasios Tefas (tefas at aiia dot csd dot auth dot gr)
00008 // 
00009 // This file is part of the ECOC PAK C++ library. It is 
00010 // provided without any warranty of fitness for any purpose.
00011 //
00012 // You can redistribute this file and/or modify it under 
00013 // the terms of the GNU Lesser General Public License (LGPL) 
00014 // as published by the Free Software Foundation, either 
00015 // version 3 of the License or (at your option) any later 
00016 // version.
00017 // (see http://www.opensource.org/licenses for more info)
00018 
00019 
00022 
00023 
00024 
00039 void
00040 uci_iris
00041   (
00042   mat& samples, 
00043   ucolvec& labels
00044   )
00045   {
00046   // load iris samples
00047   samples = \
00048     " \
00049     5.1 3.5 1.4 0.2; \
00050     4.9 3.0 1.4 0.2; \
00051     4.7 3.2 1.3 0.2; \
00052     4.6 3.1 1.5 0.2; \
00053     5.0 3.6 1.4 0.2; \
00054     5.4 3.9 1.7 0.4; \
00055     4.6 3.4 1.4 0.3; \
00056     5.0 3.4 1.5 0.2; \
00057     4.4 2.9 1.4 0.2; \
00058     4.9 3.1 1.5 0.1; \
00059     5.4 3.7 1.5 0.2; \
00060     4.8 3.4 1.6 0.2; \
00061     4.8 3.0 1.4 0.1; \
00062     4.3 3.0 1.1 0.1; \
00063     5.8 4.0 1.2 0.2; \
00064     5.7 4.4 1.5 0.4; \
00065     5.4 3.9 1.3 0.4; \
00066     5.1 3.5 1.4 0.3; \
00067     5.7 3.8 1.7 0.3; \
00068     5.1 3.8 1.5 0.3; \
00069     5.4 3.4 1.7 0.2; \
00070     5.1 3.7 1.5 0.4; \
00071     4.6 3.6 1.0 0.2; \
00072     5.1 3.3 1.7 0.5; \
00073     4.8 3.4 1.9 0.2; \
00074     5.0 3.0 1.6 0.2; \
00075     5.0 3.4 1.6 0.4; \
00076     5.2 3.5 1.5 0.2; \
00077     5.2 3.4 1.4 0.2; \
00078     4.7 3.2 1.6 0.2; \
00079     4.8 3.1 1.6 0.2; \
00080     5.4 3.4 1.5 0.4; \
00081     5.2 4.1 1.5 0.1; \
00082     5.5 4.2 1.4 0.2; \
00083     4.9 3.1 1.5 0.1; \
00084     5.0 3.2 1.2 0.2; \
00085     5.5 3.5 1.3 0.2; \
00086     4.9 3.1 1.5 0.1; \
00087     4.4 3.0 1.3 0.2; \
00088     5.1 3.4 1.5 0.2; \
00089     5.0 3.5 1.3 0.3; \
00090     4.5 2.3 1.3 0.3; \
00091     4.4 3.2 1.3 0.2; \
00092     5.0 3.5 1.6 0.6; \
00093     5.1 3.8 1.9 0.4; \
00094     4.8 3.0 1.4 0.3; \
00095     5.1 3.8 1.6 0.2; \
00096     4.6 3.2 1.4 0.2; \
00097     5.3 3.7 1.5 0.2; \
00098     5.0 3.3 1.4 0.2; \
00099     7.0 3.2 4.7 1.4; \
00100     6.4 3.2 4.5 1.5; \
00101     6.9 3.1 4.9 1.5; \
00102     5.5 2.3 4.0 1.3; \
00103     6.5 2.8 4.6 1.5; \
00104     5.7 2.8 4.5 1.3; \
00105     6.3 3.3 4.7 1.6; \
00106     4.9 2.4 3.3 1.0; \
00107     6.6 2.9 4.6 1.3; \
00108     5.2 2.7 3.9 1.4; \
00109     5.0 2.0 3.5 1.0; \
00110     5.9 3.0 4.2 1.5; \
00111     6.0 2.2 4.0 1.0; \
00112     6.1 2.9 4.7 1.4; \
00113     5.6 2.9 3.6 1.3; \
00114     6.7 3.1 4.4 1.4; \
00115     5.6 3.0 4.5 1.5; \
00116     5.8 2.7 4.1 1.0; \
00117     6.2 2.2 4.5 1.5; \
00118     5.6 2.5 3.9 1.1; \
00119     5.9 3.2 4.8 1.8; \
00120     6.1 2.8 4.0 1.3; \
00121     6.3 2.5 4.9 1.5; \
00122     6.1 2.8 4.7 1.2; \
00123     6.4 2.9 4.3 1.3; \
00124     6.6 3.0 4.4 1.4; \
00125     6.8 2.8 4.8 1.4; \
00126     6.7 3.0 5.0 1.7; \
00127     6.0 2.9 4.5 1.5; \
00128     5.7 2.6 3.5 1.0; \
00129     5.5 2.4 3.8 1.1; \
00130     5.5 2.4 3.7 1.0; \
00131     5.8 2.7 3.9 1.2; \
00132     6.0 2.7 5.1 1.6; \
00133     5.4 3.0 4.5 1.5; \
00134     6.0 3.4 4.5 1.6; \
00135     6.7 3.1 4.7 1.5; \
00136     6.3 2.3 4.4 1.3; \
00137     5.6 3.0 4.1 1.3; \
00138     5.5 2.5 4.0 1.3; \
00139     5.5 2.6 4.4 1.2; \
00140     6.1 3.0 4.6 1.4; \
00141     5.8 2.6 4.0 1.2; \
00142     5.0 2.3 3.3 1.0; \
00143     5.6 2.7 4.2 1.3; \
00144     5.7 3.0 4.2 1.2; \
00145     5.7 2.9 4.2 1.3; \
00146     6.2 2.9 4.3 1.3; \
00147     5.1 2.5 3.0 1.1; \
00148     5.7 2.8 4.1 1.3; \
00149     6.3 3.3 6.0 2.5; \
00150     5.8 2.7 5.1 1.9; \
00151     7.1 3.0 5.9 2.1; \
00152     6.3 2.9 5.6 1.8; \
00153     6.5 3.0 5.8 2.2; \
00154     7.6 3.0 6.6 2.1; \
00155     4.9 2.5 4.5 1.7; \
00156     7.3 2.9 6.3 1.8; \
00157     6.7 2.5 5.8 1.8; \
00158     7.2 3.6 6.1 2.5; \
00159     6.5 3.2 5.1 2.0; \
00160     6.4 2.7 5.3 1.9; \
00161     6.8 3.0 5.5 2.1; \
00162     5.7 2.5 5.0 2.0; \
00163     5.8 2.8 5.1 2.4; \
00164     6.4 3.2 5.3 2.3; \
00165     6.5 3.0 5.5 1.8; \
00166     7.7 3.8 6.7 2.2; \
00167     7.7 2.6 6.9 2.3; \
00168     6.0 2.2 5.0 1.5; \
00169     6.9 3.2 5.7 2.3; \
00170     5.6 2.8 4.9 2.0; \
00171     7.7 2.8 6.7 2.0; \
00172     6.3 2.7 4.9 1.8; \
00173     6.7 3.3 5.7 2.1; \
00174     7.2 3.2 6.0 1.8; \
00175     6.2 2.8 4.8 1.8; \
00176     6.1 3.0 4.9 1.8; \
00177     6.4 2.8 5.6 2.1; \
00178     7.2 3.0 5.8 1.6; \
00179     7.4 2.8 6.1 1.9; \
00180     7.9 3.8 6.4 2.0; \
00181     6.4 2.8 5.6 2.2; \
00182     6.3 2.8 5.1 1.5; \
00183     6.1 2.6 5.6 1.4; \
00184     7.7 3.0 6.1 2.3; \
00185     6.3 3.4 5.6 2.4; \
00186     6.4 3.1 5.5 1.8; \
00187     6.0 3.0 4.8 1.8; \
00188     6.9 3.1 5.4 2.1; \
00189     6.7 3.1 5.6 2.4; \
00190     6.9 3.1 5.1 2.3; \
00191     5.8 2.7 5.1 1.9; \
00192     6.8 3.2 5.9 2.3; \
00193     6.7 3.3 5.7 2.5; \
00194     6.7 3.0 5.2 2.3; \
00195     6.3 2.5 5.0 1.9; \
00196     6.5 3.0 5.2 2.0; \
00197     6.2 3.4 5.4 2.3; \
00198     5.9 3.0 5.1 1.8; \
00199     ";
00200   
00201   // load iris labels
00202   labels = \
00203     " \
00204     1 1 1 1 1 1 1 1 1 1  \
00205     1 1 1 1 1 1 1 1 1 1  \
00206     1 1 1 1 1 1 1 1 1 1  \
00207     1 1 1 1 1 1 1 1 1 1  \
00208     1 1 1 1 1 1 1 1 1 1  \
00209     2 2 2 2 2 2 2 2 2 2  \
00210     2 2 2 2 2 2 2 2 2 2  \
00211     2 2 2 2 2 2 2 2 2 2  \
00212     2 2 2 2 2 2 2 2 2 2  \
00213     2 2 2 2 2 2 2 2 2 2  \
00214     3 3 3 3 3 3 3 3 3 3  \
00215     3 3 3 3 3 3 3 3 3 3  \
00216     3 3 3 3 3 3 3 3 3 3  \
00217     3 3 3 3 3 3 3 3 3 3  \
00218     3 3 3 3 3 3 3 3 3 3; \
00219     ";
00220   }
00221 
00222 
00223 
00237 mat
00238 uci_iris()
00239   {
00240   // load iris samples
00241   mat samples = \
00242     " \
00243     5.1 3.5 1.4 0.2; \
00244     4.9 3.0 1.4 0.2; \
00245     4.7 3.2 1.3 0.2; \
00246     4.6 3.1 1.5 0.2; \
00247     5.0 3.6 1.4 0.2; \
00248     5.4 3.9 1.7 0.4; \
00249     4.6 3.4 1.4 0.3; \
00250     5.0 3.4 1.5 0.2; \
00251     4.4 2.9 1.4 0.2; \
00252     4.9 3.1 1.5 0.1; \
00253     5.4 3.7 1.5 0.2; \
00254     4.8 3.4 1.6 0.2; \
00255     4.8 3.0 1.4 0.1; \
00256     4.3 3.0 1.1 0.1; \
00257     5.8 4.0 1.2 0.2; \
00258     5.7 4.4 1.5 0.4; \
00259     5.4 3.9 1.3 0.4; \
00260     5.1 3.5 1.4 0.3; \
00261     5.7 3.8 1.7 0.3; \
00262     5.1 3.8 1.5 0.3; \
00263     5.4 3.4 1.7 0.2; \
00264     5.1 3.7 1.5 0.4; \
00265     4.6 3.6 1.0 0.2; \
00266     5.1 3.3 1.7 0.5; \
00267     4.8 3.4 1.9 0.2; \
00268     5.0 3.0 1.6 0.2; \
00269     5.0 3.4 1.6 0.4; \
00270     5.2 3.5 1.5 0.2; \
00271     5.2 3.4 1.4 0.2; \
00272     4.7 3.2 1.6 0.2; \
00273     4.8 3.1 1.6 0.2; \
00274     5.4 3.4 1.5 0.4; \
00275     5.2 4.1 1.5 0.1; \
00276     5.5 4.2 1.4 0.2; \
00277     4.9 3.1 1.5 0.1; \
00278     5.0 3.2 1.2 0.2; \
00279     5.5 3.5 1.3 0.2; \
00280     4.9 3.1 1.5 0.1; \
00281     4.4 3.0 1.3 0.2; \
00282     5.1 3.4 1.5 0.2; \
00283     5.0 3.5 1.3 0.3; \
00284     4.5 2.3 1.3 0.3; \
00285     4.4 3.2 1.3 0.2; \
00286     5.0 3.5 1.6 0.6; \
00287     5.1 3.8 1.9 0.4; \
00288     4.8 3.0 1.4 0.3; \
00289     5.1 3.8 1.6 0.2; \
00290     4.6 3.2 1.4 0.2; \
00291     5.3 3.7 1.5 0.2; \
00292     5.0 3.3 1.4 0.2; \
00293     7.0 3.2 4.7 1.4; \
00294     6.4 3.2 4.5 1.5; \
00295     6.9 3.1 4.9 1.5; \
00296     5.5 2.3 4.0 1.3; \
00297     6.5 2.8 4.6 1.5; \
00298     5.7 2.8 4.5 1.3; \
00299     6.3 3.3 4.7 1.6; \
00300     4.9 2.4 3.3 1.0; \
00301     6.6 2.9 4.6 1.3; \
00302     5.2 2.7 3.9 1.4; \
00303     5.0 2.0 3.5 1.0; \
00304     5.9 3.0 4.2 1.5; \
00305     6.0 2.2 4.0 1.0; \
00306     6.1 2.9 4.7 1.4; \
00307     5.6 2.9 3.6 1.3; \
00308     6.7 3.1 4.4 1.4; \
00309     5.6 3.0 4.5 1.5; \
00310     5.8 2.7 4.1 1.0; \
00311     6.2 2.2 4.5 1.5; \
00312     5.6 2.5 3.9 1.1; \
00313     5.9 3.2 4.8 1.8; \
00314     6.1 2.8 4.0 1.3; \
00315     6.3 2.5 4.9 1.5; \
00316     6.1 2.8 4.7 1.2; \
00317     6.4 2.9 4.3 1.3; \
00318     6.6 3.0 4.4 1.4; \
00319     6.8 2.8 4.8 1.4; \
00320     6.7 3.0 5.0 1.7; \
00321     6.0 2.9 4.5 1.5; \
00322     5.7 2.6 3.5 1.0; \
00323     5.5 2.4 3.8 1.1; \
00324     5.5 2.4 3.7 1.0; \
00325     5.8 2.7 3.9 1.2; \
00326     6.0 2.7 5.1 1.6; \
00327     5.4 3.0 4.5 1.5; \
00328     6.0 3.4 4.5 1.6; \
00329     6.7 3.1 4.7 1.5; \
00330     6.3 2.3 4.4 1.3; \
00331     5.6 3.0 4.1 1.3; \
00332     5.5 2.5 4.0 1.3; \
00333     5.5 2.6 4.4 1.2; \
00334     6.1 3.0 4.6 1.4; \
00335     5.8 2.6 4.0 1.2; \
00336     5.0 2.3 3.3 1.0; \
00337     5.6 2.7 4.2 1.3; \
00338     5.7 3.0 4.2 1.2; \
00339     5.7 2.9 4.2 1.3; \
00340     6.2 2.9 4.3 1.3; \
00341     5.1 2.5 3.0 1.1; \
00342     5.7 2.8 4.1 1.3; \
00343     6.3 3.3 6.0 2.5; \
00344     5.8 2.7 5.1 1.9; \
00345     7.1 3.0 5.9 2.1; \
00346     6.3 2.9 5.6 1.8; \
00347     6.5 3.0 5.8 2.2; \
00348     7.6 3.0 6.6 2.1; \
00349     4.9 2.5 4.5 1.7; \
00350     7.3 2.9 6.3 1.8; \
00351     6.7 2.5 5.8 1.8; \
00352     7.2 3.6 6.1 2.5; \
00353     6.5 3.2 5.1 2.0; \
00354     6.4 2.7 5.3 1.9; \
00355     6.8 3.0 5.5 2.1; \
00356     5.7 2.5 5.0 2.0; \
00357     5.8 2.8 5.1 2.4; \
00358     6.4 3.2 5.3 2.3; \
00359     6.5 3.0 5.5 1.8; \
00360     7.7 3.8 6.7 2.2; \
00361     7.7 2.6 6.9 2.3; \
00362     6.0 2.2 5.0 1.5; \
00363     6.9 3.2 5.7 2.3; \
00364     5.6 2.8 4.9 2.0; \
00365     7.7 2.8 6.7 2.0; \
00366     6.3 2.7 4.9 1.8; \
00367     6.7 3.3 5.7 2.1; \
00368     7.2 3.2 6.0 1.8; \
00369     6.2 2.8 4.8 1.8; \
00370     6.1 3.0 4.9 1.8; \
00371     6.4 2.8 5.6 2.1; \
00372     7.2 3.0 5.8 1.6; \
00373     7.4 2.8 6.1 1.9; \
00374     7.9 3.8 6.4 2.0; \
00375     6.4 2.8 5.6 2.2; \
00376     6.3 2.8 5.1 1.5; \
00377     6.1 2.6 5.6 1.4; \
00378     7.7 3.0 6.1 2.3; \
00379     6.3 3.4 5.6 2.4; \
00380     6.4 3.1 5.5 1.8; \
00381     6.0 3.0 4.8 1.8; \
00382     6.9 3.1 5.4 2.1; \
00383     6.7 3.1 5.6 2.4; \
00384     6.9 3.1 5.1 2.3; \
00385     5.8 2.7 5.1 1.9; \
00386     6.8 3.2 5.9 2.3; \
00387     6.7 3.3 5.7 2.5; \
00388     6.7 3.0 5.2 2.3; \
00389     6.3 2.5 5.0 1.9; \
00390     6.5 3.0 5.2 2.0; \
00391     6.2 3.4 5.4 2.3; \
00392     5.9 3.0 5.1 1.8; \
00393     ";
00394   
00395   return samples;
00396   }
00397 
00398 
00399 
 All Data Structures Namespaces Files Functions Variables Typedefs Enumerator Defines