abstract class with inherite handle class

조회 수: 1 (최근 30일)
Muhammad Khalid
Muhammad Khalid 2019년 8월 11일
댓글: Matt J 2019년 8월 14일
hi,
i use this code to access file of abstract class with inherited handle class I use this code .....
classdef(Abstract) featureGenerationUnit< handles
properties
EEG;
features;
names;
INFO;
status;
end
methods
function obj = featureGenerationUnit(EEG, INFO)
obj.EEG = EEG;
obj.INFO = INFO;
end
function loadData(EEG)
obj.EEG = EGG;
end
function loadInfo(INFO)
obj.INFO = INFO;
end
end
methods(Abstract)
getFeatures(obj)
end
end
i use these command to make obj but it gives error
mc = ?MyClass;
>> mc = meta.class.fromName('featureGenerationUnit');
>> fGU = featureGenerationUnit;
Not enough input arguments.
Error in featureGenerationUnit (line 12)
obj.EEG = EEG;
other error is
fGU = featureGenerationUnit;
Error using featureGenerationUnit
The specified superclass 'handles' contains a parse error, cannot
be found on MATLAB's search path, or is shadowed by another file
with the same name.
  댓글 수: 2
Steven Lord
Steven Lord 2019년 8월 11일
FYI for others answering this question, I believe this other question is related.
Matt J
Matt J 2019년 8월 14일
Muhammad's comment moved here:
I use a code for preprocessing and feature Extraction and I have no code for support vector machine but i have other code which has feature is preprocessing , feature extraction and svm which is based on EEGLAB .Can I use a Code which is based on only for support vector machine without EEGLAB ?

댓글을 달려면 로그인하십시오.

답변 (1개)

Matt J
Matt J 2019년 8월 11일
You cannot create an instance of an abstract class. Also, your constructor expects arguments EEG and INFO, which you have not provided.

카테고리

Help CenterFile Exchange에서 EEG/MEG/ECoG에 대해 자세히 알아보기

Community Treasure Hunt

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

Start Hunting!

Translated by