Sample Data: Fisher's Irises

Source Notebook

Fisher's iris data

Details

The data set consists of 50 samples from each of three species of iris flowers (setosa, versicolor and virginica). Four features were measured from each flower, the length and the width of the sepal and petal. The test and training sets were constructed by stratified random sampling, using 30% of the data for the test set and the rest for the training set.

(4 columns, 150 rows)

Examples

Basic Examples

View the data:

In[1]:=
ResourceData[ResourceObject["Sample Data: Fisher's Irises"]]
Out[2]=

Visualization

Compare mean petal lengths for setosa, versicolor, and virginica:

In[3]:=
BarChart[Mean /@ GroupBy[ResourceData[ResourceObject[
             "Sample Data: Fisher's Irises"]], "Species"][All, All, "PetalLength"], ChartLabels -> Automatic]
Out[3]=

Analysis

Train a classifier:

In[4]:=
c = Classify[
  ResourceData["Sample Data: Fisher's Irises", "TrainingData"]]
Out[4]=

Obtain general information about the classifier:

In[5]:=
ClassifierInformation[c]
Out[5]=

Generate a ClassifierMeasurementsObject of the classifier with the test set:

In[6]:=
cm = ClassifierMeasurements[c, ResourceData["Sample Data: Fisher's Irises", "TestData"]]
Out[6]=

Visualize the accuracy of the classifier:

In[7]:=
cm["ConfusionMatrixPlot"]
Out[7]=

Wolfram Research, "Sample Data: Fisher's Irises" from the Wolfram Data Repository (2020)   https://doi.org/10.24097/wolfram.89373.data

Data Resource History

Source Metadata

Data Downloads

Publisher Information