How to fix "error using class. Not enough input arguments"?
이전 댓글 표시
Wrote this function code as part of a worksheet. It was working normally but all of a sudden I am getting an error message. I didn't change anything so I have no clue how this happened?
% Find the time points corresponding to the onset and offset times from the classifier
[onset, offset] = change_times(class, time);
(error comes after the line above)
% Display the number of onset/offset times determined with each classifier
length(onset);
disp(['Onset Times = ', num2str(length(onset)),])
length(offset);
disp(['Offset Times = ', num2str(length(offset)),])
답변 (1개)
You had probably shadowed the function class() with some variable by the same name -- which is something you should avoid.
which class -all
help class
Since said variable is now missing and not shown in the provided code excerpt, you'll have to figure out where it went.
카테고리
도움말 센터 및 File Exchange에서 Logical에 대해 자세히 알아보기
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!