Feature labels |
One of the fields in the dataset definition concerns the feature labels (featlab). For a proper functioning of PRTools
they are not essential with one important exception (see below). Sometimes it may even be better to leave this field empty as handling the feature labels in case of large feature sizes causes a large overhead (e.g. in case all pixels of an image are used as feature). In case feature labels are needed and not supplied PRTools
just numbers them.
The main purpose of feature labels is to annotate the data and possibly plots and tables based on the data. The enables the user to understand results in terms of the original measurements. Here is a simple example. It assumes that prdatasets are loaded and in the path. The feature labels in the dataset A, which the flower properties used in the Iris dataset, are copied for the two selected features into B. These feature labels are used to annotate the scatter plot.
A = iris; % load the Iris dataset getfeatlab(A) % get the feature labels % sepal length % sepal width % petal length % petal width B = A(:,[2 3]); % Select just two feature scatterd(B); % show the scatterplot
Feature labels are also used after classification to annotate the classification matrix with the class names. In this case it is essential that they exist as they are used to estimate the most likely class for every object in the classification matrix. PRTools
handles this automatically. Users should just avoid to change the feature labels (which are the class names).
R.P.W. Duin
, January 28, 2013Feature labels |