Basic Classification using MATLAB
MATLAB is a high-level language and interactive environment for numerical computation, visualization, and programming. Using MATLAB, we will analyse data, develop algorithms, and create models and applications.
The Fisher's Iris data set is a multivariate data set introduced by Sir Ronald Fisher (1936) as an example of discriminant analysis. It is sometimes called Anderson's Iris data set because Edgar Anderson collected the data to quantify the morphologic variation of Iris flowers of three related species.
We will use MATLAB software to classify the Fisher's IRIS dataset and then will get into detail of this code line by line
Preview
Getting into detail of this code
First line was
What this line does?
Loads inbuilt Fisher's iris data into workspace as a collection of matrix(meas) with dimension 150x4 and vector(species) with dimension 150x1

Second line was
What this line does?
Creates a scatter plot of
Third line
What this line does?
Adds label to the graph, xlabel adds label to x-axis and ylabel adds label to y-axis.
The Fisher's Iris data set is a multivariate data set introduced by Sir Ronald Fisher (1936) as an example of discriminant analysis. It is sometimes called Anderson's Iris data set because Edgar Anderson collected the data to quantify the morphologic variation of Iris flowers of three related species.
We will use MATLAB software to classify the Fisher's IRIS dataset and then will get into detail of this code line by line
Preview
load fisheriris;
gscatter(meas(:,1), meas(:,2), species,'rgb','osd');
xlabel('Sepal length');
ylabel('Sepal width');
Outputgscatter(meas(:,1), meas(:,2), species,'rgb','osd');
xlabel('Sepal length');
ylabel('Sepal width');
Getting into detail of this code
First line was
load fisheriris;
What this line does?
Loads inbuilt Fisher's iris data into workspace as a collection of matrix(meas) with dimension 150x4 and vector(species) with dimension 150x1

Second line was
gscatter(meas(:,1), meas(:,2), species,'rgb','osd');
What this line does?
Creates a scatter plot of
- meas(:,1) [column1 from meas matrix]
- meas(:,2) [column2 from meas matrix]
Third line
xlabel('Sepal length');
ylabel('Sepal width');
ylabel('Sepal width');
What this line does?
Adds label to the graph, xlabel adds label to x-axis and ylabel adds label to y-axis.
Subscribe to:
Post Comments
(
Atom
)


No comments :
Post a Comment