Happy new year for all the PRtools team.
I am having a little problem with the setfeatdom function, I think that could be a bug. The problem arrises with the following code:
dsTarget_dataset = dataset( featureMatrix, labels)
100695 by 40 dataset with 14 classes: [74435 8066 7248 2542 150 83 2 6869 802 16 229 106 15 132]
dsTarget_dataset = setfeatdom(dsTarget_dataset, cFeaturesDomain, feature_properties.DirectionalFeatures );
Where featureMatrix is a [100695 x 40] matrix. Then for the features indexed by the feature_properties.DirectionalFeatures array I set the domains cFeaturesDomain. After this two instructions, when a try to sample the dataset with:
dsTarget_dataset(1:10,:)
the error arrises
??? Index exceeds matrix dimensions.
Error in ==> D:\Mariano\papers\ECG Classification\scripts\common\prtools\@dataset\subsref.p>subsref
at 78
I think that the problem is in the position of the features to set a new domain. For example, if I put the two features with new domain (indexes [38 39]) in the extreme right of the matrix, the problem is solved:
dsTarget_dataset = dataset( [featureMatrix(:,[1:37 40]) featureMatrix(:,[38 39])], labels);
dsTarget_dataset = setfeatdom(dsTarget_dataset, cFeaturesDomain, [39 40] );
dsTarget_dataset(1:10,:)
10 by 40 dataset with 14 classes: [9 0 0 0 0 0 0 0 0 0 0 0 0 1]
Hope to be clear enough, any comments or error I would be doing please tell me.
Best regards,
Mariano.

