如何在 MATLAB 中读取 .dat 文件
我正在尝试从 PTB 数据集中读取 ECG 信号,文件扩展名是“.dat”,我正在使用 Matlab 函数:其中
load('s0484_re.dat');
“s0484_re.dat”是文件名 但我收到这样的错误:
Error using load ASCII 文件第 1 行的未知文本 s0484_re.dat “……”。
signal2image 中的错误(第 8 行) 加载('s0484_re.dat');
我怎样才能正确读取这个文件? 任何帮助将不胜感激..
I am trying to read an ECG signal from PTB dataset, the file extension is ".dat" ,i am using Matlab function for that:
load('s0484_re.dat');
where "s0484_re.dat" is the file name
but i am getting an error like this:
Error using load
Unknown text on line number 1 of ASCII file
s0484_re.dat
"�����\�".
Error in signal2image (line 8)
load('s0484_re.dat');
how i can read this file correctly?
Any help will be appreciated..
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
文件扩展名
.dat
可用于许多不同类型的二进制数据文件,并且不会告诉您数据的格式。通过搜索“PTB dataset”我 发现该数据集中的数据文件采用“WaveForm DataBase (WFDB) 格式”的信息,并由在 mathworks.com 中搜索“WFDB” 我发现了一些链接,包括 用于处理 WFDB 文件的工具箱。尝试此工具箱,如果它不能解决您的问题,请更新您的问题。
The file extension
.dat
can be used for many different types of binary data file and doesn't tell you what format the data is in.By searching on 'PTB dataset` I found the information that the data files in this dataset are in 'WaveForm DataBase (WFDB) format', and by searching mathworks.com for 'WFDB' I found a few links including a toolbox for handling WFDB files. Try this toolbox, and update your question if it doesn't solve your problem.