IRootLab
An Open-Source MATLAB toolbox for vibrational biospectroscopy
data_split_classes.m File Reference

Detailed Description

Splits data according to classes. Returns an array of structures.

Split_classes separates data according to the class of each instance. Instances are the rows of 'data'.

Definition in file data_split_classes.m.

Go to the source code of this file.

Functions

function data_split_classes (in data, in hierarchy)
 

Function Documentation

function data_split_classes ( in  data,
in  hierarchy 
)
Parameters
datairdata object
hierarchyclasslabel levels to be taken into account
Returns
[pieces] or [pieces, map]. pieces: array of irdata objects; map cell array of vectors containing the indexes of the rows in the original dataset that went to each element of piece.