perClass Documentation
version 5.4 (7-Dec-2018)
 SUBSET Return a subset of data set defined by property values

     B=SUBSET(A,CLASSES)
     B=SUBSET(A,PROP,VALUES,PROP2,VALUES2,...)
     [B,REST,IND,IND2]=subset(A,CLASSES)

 INPUT
     A         SDDATA object
     CLASSES   Cell array with class names
     PROP      Property name (e.g. 'patient')
     VALUES    Category names or list indices

 OUTPUT
     B         SDDATA object
     REST      SDDATA. The remainder of A after selecting B
     IND       Indices of B samples in A
     IND2      Indices of REST samples in A

 DESCRIPTION
 SUBSET method provides selection of samples based on label values.  The
 simplest use is to retrieve a subset of classes by specifying their names
 in CLASSES. General syntax allows us to define a property PROP and VALUES
 either by string names or by indices.  Samples with any of the VALUES are
 returned (logical OR). When combining multiple selections, an intersection
 (logical AND) is adopted.

 EXAMPLE
 Selecting cancer from the first five patients:
   b=subset(a,'class','cancer','patient',1:5)