I’m using sleep EEG signal from sleep-edfx database in Matlab for the purpose of sleep stages extraction. I have used wfdb2mat function for the signal but I have trouble reading hypnogram annotations in Matlab.
I have entered this code:
wfdb2mat('sleep-edfx/SC4002EC-Hypnogram.edf')
hypno=load('SC4002EC-Hypnogram_edfm');
In fact, I can’t find the relation between the hypnogram values & sleep-stages
I want to align the hypnogram with the corresponding EEG signal so that hypnogram values describing the sleep stage and the sample index relevant to time. In addition, the signal & it’s hypnogram must have the same length.
I really need your help. thanks alot
here is my configuration:
config =
MATLAB_VERSION: '8.3.0.532 (R2014a)'
inOctave: 0
WFDB_VERSION: '[10.5.24]'
WFDB_JAVA_HOME: ' E:\Thesis\Matlab Codes\'
WFDB_NATIVE_BIN: ' E:\Thesis\Matlab Codes\nativelibs\windows\'
EXECUTING_DIR: ' null'
osName: 'windows'
fullOsName: ' Windows 7'
osArch: ' amd64'
customArchFlag: ' false'
OSVersion: ' 6.1'
JVMVersion: ' 1.7.0_11]'
MATLAB_PATH: 'E:\Thesis\Matlab Codes\'
WFDB_JAVA_VERSION: 'wfdb-app-JVM7-0-9-10.jar'
DEBUG_LEVEL: 0
NETWORK_WAIT_TIME: 1000
MATLAB_ARCH: 'win64'
WFDB_PATH: '. E:\Thesis\Matlab Codes\..\database\ http://physionet.org/physiobank/database/'
WFDBCAL: ' E:\Thesis\Matlab Codes\\database\wfdbcal'
WFDB_CUSTOMLIB: 0
CACHE_SOURCE: 'http://physionet.org/physiobank/database/'
CACHE_DEST: 'E:\Thesis\Matlab Codes\..\database\'
CACHE: 1