WFDB - reading in ECG files

I have downloaded the WFDB toolbox from PhysioNet for MATLAB.
I am trying to read in an ECG file (nsr001.ecg) downloaded from PhysioBank into MATLAB but all my attempts have failed so far! I am using the 'rdsamp' command.
I have downloaded nsr001.ecg (signal) and nsr001.hea (annotation) files. The path where both of the files are located has been added to MATLAB.
What is the correct syntax to use to read the ECG data files from my drive into MATLAB using the WFDB toolbox commands?
Thanks.

回答 (4 件)

Mauro Alejandro Pereira
Mauro Alejandro Pereira 2017 年 11 月 8 日

1 投票

I have the same problem, in wfdbdemo.m it there the solution.
Mohsen  Davarynejad
Mohsen Davarynejad 2011 年 12 月 10 日

0 投票

First you have to download the rdsign212.m and rdsign212.dll. To read the first N samples of an M-lead ECG (supposing that the data is saved in binary format) you have to use the following command (assuming your data is saved in ECGData.ecg):
ECGSignal = rdsign212('ECGData.ecg',M,1,N)

3 件のコメント

M.
M. 2011 年 12 月 10 日
Mohsen, thanks for your reply.
I thought the WFDB toolbox includes all the commands to read in an ECG file?
The documentation on the PhysioNet website indicates that the 'rdsamp' command should be used to read in files from the database.
'rdsamp' is included in the toolbox, 'rdsign212' isn't?
Mohsen  Davarynejad
Mohsen Davarynejad 2011 年 12 月 10 日
My recommendation was for the case you are using MIT-database ECG. Sorry for the confusion!!
M.
M. 2011 年 12 月 10 日
Yes I am using the MIT database (PhysioBank). The help documentation for the WFDB toolbox indicates that 'rdsamp' should be used.

サインインしてコメントする。

M.
M. 2011 年 12 月 10 日

0 投票

I have just found out that the 'rdsamp' function requires a .dat file as the input.
.dat files from the PhysioBank database contain the digitised ECG as well as the beat annotations.
.ecg files only contain beat annotations.
fradaric joseph
fradaric joseph 2012 年 2 月 24 日

0 投票

Add those dat files from MIT BIH into the working directory, Then use import wizard, now you can use the commands like rdssamp..etc

1 件のコメント

mina
mina 2014 年 5 月 25 日
what is input wizard?

サインインしてコメントする。

カテゴリ

ヘルプ センター および File ExchangeECG / EKG についてさらに検索

質問済み:

M.
2011 年 12 月 10 日

回答済み:

2017 年 11 月 8 日

Community Treasure Hunt

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

Start Hunting!

Translated by