I have trained the data using linear SVM. And from classification learner, I have exported the trained model to work space. I have written the following code for test data prediction as follows.. function Test_svm1() d = dir('*.xlsx'); fileName = d.

1 view (last 30 days)
I have trained the data using linear SVM. And from classification learner, I have exported the trained model to work space. I have written the following code for test data prediction as follows.. function Test_svm1() d = dir('*.xlsx'); fileName = d.name; %// Get the file name filename = 'DBModified_DTCWT_4Level_TST.xlsx'; sheet = 1; trainingData = xlsread(fileName,sheet); [trainedClassifier, validationAccuracy] = trainClassifier(trainingData);
filename = 'DBModified_DTCWT_4Level_TST.xlsx'; T = xlsread(filename); yfit=predict(trainedModel,T(:,trainedModel.predictFcn)); end But I get the following error Function 'subsindex' is not defined for values of class 'cell'. Error in trainClassifier (line 48) predictors = inputTable(:, predictorNames);
Error in Test_svm1 (line 7) [trainedClassifier, validationAccuracy] = trainClassifier(trainingData); Pl suggest me where i have done mistake Regards Aditi Vedalanka

Answers (0)

Categories

Find more on Deep Learning Toolbox in Help Center and File Exchange

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!