I was using a Matlab R2015b's Classification Learner Toolbox. I was successful in importing file data and export it into an Export Model, and i got a structure named trainedClassifier.
Import process #1
Import process #2
Training process with PCA implemented & Multi Class SVM (One vs All validation)
trainedClassifier variable generated from ToolBox
fetureVector variable which used for testing
yfit = trainedClassifier.predictFcn(featureVector)
>> yfit = trainedClassifier.predictFcn(featureVector)
Then i got an error output as a follows :
Function 'subsindex' is not defined for values of class 'cell'.Error in mlearnapp.internal.model.DatasetSpecification>@(t)t(:,predictorNames) (line 135)extractPredictorsFromTableFcn = @(t) t(:,predictorNames);Error in mlearnapp.internal.model.DatasetSpecification>@(x)extractPredictorsFromTableFcn(splitMatricesInTableFcn(convertMatrixToTableFcn(x)))(line 136)extractPredictorsFcn = @(x) extractPredictorsFromTableFcn(splitMatricesInTableFcn(convertMatrixToTableFcn(x)));Error in mlearnapp.internal.model.DatasetSpecification>@(x)exportableClassifier.predictFcn(extractPredictorsFcn(x)) (line 137)exportableClassifier.predictFcn = @(x) exportableClassifier.predictFcn(extractPredictorsFcn(x));
What is the problem and solutions?
Thanks in advance.
Best Answer