I am new on matlab and installed R2017B and preparing a project emotion based music player
1 次查看(过去 30 天)
显示 更早的评论
Error in classreg.learning.paramoptim.parseOptimizationArgs (line 5) [OptimizeHyperparameters,~,~,RemainingArgs] = internal.stats.parseArgs(...
Error in fitcknn (line 247) [IsOptimizing, RemainingArgs] = classreg.learning.paramoptim.parseOptimizationArgs(varargin);
Error in main_GUI>Recognition_Callback (line 236) c=fitcknn(test_feature,fea,group);
Error in gui_mainfcn (line 95) feval(varargin{:});
Error in main_GUI (line 43) gui_mainfcn(gui_State, varargin{:});
Error in matlab.graphics.internal.figfile.FigFile/read>@(hObject,eventdata)main_GUI('Recognition_Callback',hObject,eventdata,guidata(hObject)) Error while evaluating UIControl Callback.
4 个评论
Jan
2018-2-23
编辑:Jan
2018-2-23
Currently your code is not readable. Mark it and press the "{} Code" button to format it.
It would be kind, if you post the relevant part of the code only. Otherwise all readers have to dig in the code at first to find out, where you need what. We cannot run your code, because the FIG file is not provided. And you have posted only the part of the error message, which explains where the problem occurs, but not the line about what the problem is.
回答(1 个)
Don Mathis
2018-2-23
In your posted code, I see a single call to 'fitcknn' and it is passed 3 arguments:
c=fitcknn(test_feature,fea,group);
fitcknn does not take 3 arguments. It takes two, plus optional name-value pair arguments that appear in pairs. So I suspect that the 'group' argument is misplaced.
0 个评论
另请参阅
类别
在 Help Center 和 File Exchange 中查找有关 Develop uifigure-Based Apps 的更多信息
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!