【肌电信号】脉搏信号分析(去噪+特征提取)matlab 源码含GUI

2023-11-07 08:10

本文主要是介绍【肌电信号】脉搏信号分析(去噪+特征提取)matlab 源码含GUI,希望对大家解决编程问题提供一定的参考价值,需要的开发者们随着小编来一起学习吧!

一、简介

EMG,应用电子学仪器记录肌肉静止或收缩时的电活动,及应用电刺激检查神经、肌肉兴奋及传导功能的方法。英文简称EMG。通过此检查可以确定周围神经、神经元、神经肌肉接头及肌肉本身的功能状态。\ 通过测定运动单位电位的时限、波幅,安静情况下有无自发的电活动,以及肌肉大力收缩的波型及波幅,可区别神经原性损害和肌原性损害,诊断脊髓前角急、慢性损害(如脊髓前灰质炎、运动神经元疾病),神经根及周围神经病变(例如肌电图检查可以协助确定神经损伤的部位、程度、范围和预后)。另外对神经嵌压性病变、神经炎、遗传代谢障碍神经病、各种肌肉病也有诊断价值。此外,肌电图还用于在各种疾病的治疗过程中追踪疾病的恢复过程及疗效。\ 利用计算机技术,可作肌电图的自动分析,如解析肌电图、单纤维肌电图以及巨肌电图等,提高诊断的阳性率。\ 肌电图检查多用针电极及应用电刺激技术,检查过程中有一定的痛苦及损伤 ,因此除非必要 ,不可滥用此项检查。另外,检查时要求肌肉能完全放松或作不同程度的用力,因而要求受检者充分合作。对于某些检查,检查前要停药,如新斯地明类药物应于检查前16小时停用\ 记录肌肉动作电位的曲线(电描记图)称为肌电图。缩写为EMG。实际使用的描记方法有两种:一种是表面导出法,即把电极贴附在皮肤上导出电位的方法;另一种是针电极法,即把针电极刺入肌肉导出局部电位的方法。用后一种方法能分别记录肌肉每次的动作电位,而根据从每秒数次到二、三十次的肌肉动作电位情况,发现频率的异常。应用肌电图还可以诊断运动机能失常的原因。平常所用的针电极称为同心电极,它是把细针状电极穿过注射针的中心,两者绝缘固定制成的。

二、源代码

``` %% Program Start %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% %% 名称:信号处理课程设计 %% 功能:脉搏检测系统GUI主界面 %%  %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% %%

function varargout = mainjiemian(varargin) % MAINJIEMIAN MATLAB code for mainjiemian.fig % MAINJIEMIAN, by itself, creates a new MAINJIEMIAN or raises the existing % singleton. % % H = MAINJIEMIAN returns the handle to a new MAINJIEMIAN or the handle to % the existing singleton. % % MAINJIEMIAN('CALLBACK',hObject,eventData,handles,...) calls the local % function named CALLBACK in MAINJIEMIAN.M with the given input arguments. % % MAINJIEMIAN('Property','Value',...) creates a new MAINJIEMIAN or raises the % existing singleton*. Starting from the left, property value pairs are % applied to the GUI before mainjiemianOpeningFcn gets called. An % unrecognized property name or invalid value makes property application % stop. All inputs are passed to mainjiemianOpeningFcn via varargin. % % *See GUI Options on GUIDE's Tools menu. Choose "GUI allows only one % instance to run (singleton)". % % See also: GUIDE, GUIDATA, GUIHANDLES

% Edit the above text to modify the response to help mainjiemian

% Last Modified by GUIDE v2.5 29-Apr-2021 12:18:07

% Begin initialization code - DO NOT EDIT guiSingleton = 1; guiState = struct('guiName', mfilename, ... 'guiSingleton', guiSingleton, ... 'guiOpeningFcn', @mainjiemianOpeningFcn, ... 'guiOutputFcn', @mainjiemianOutputFcn, ... 'guiLayoutFcn', [] , ... 'guiCallback', []); if nargin && ischar(varargin{1}) guiState.gui_Callback = str2func(varargin{1}); end

if nargout [varargout{1:nargout}] = guimainfcn(guiState, varargin{:}); else guimainfcn(guiState, varargin{:}); end % End initialization code - DO NOT EDIT

% --- Executes just before mainjiemian is made visible. function mainjiemian_OpeningFcn(hObject, eventdata, handles, varargin) % This function has no output args, see OutputFcn. % hObject handle to figure % eventdata reserved - to be defined in a future version of MATLAB % handles structure with handles and user data (see GUIDATA) % varargin command line arguments to mainjiemian (see VARARGIN)

% Choose default command line output for mainjiemian handles.output = hObject; ha=axes('units','normalized','position',[0 0 1 1]); uistack(ha,'down') II=imread('1.jpg'); image(II) colormap gray set(ha,'handlevisibility','off','visible','off'); % Update handles structure

% Update handles structure guidata(hObject, handles);

% UIWAIT makes mainjiemian wait for user response (see UIRESUME) % uiwait(handles.figure1);

% --- Outputs from this function are returned to the command line. function varargout = mainjiemian_OutputFcn(hObject, eventdata, handles) % varargout cell array for returning output args (see VARARGOUT); % hObject handle to figure % eventdata reserved - to be defined in a future version of MATLAB % handles structure with handles and user data (see GUIDATA)

% Get default command line output from handles structure varargout{1} = handles.output;

% --- Executes on button press in togglebutton1. function togglebutton1_Callback(hObject, eventdata, handles) untitled; % hObject handle to togglebutton1 (see GCBO) % eventdata reserved - to be defined in a future version of MATLAB % handles structure with handles and user data (see GUIDATA)

% Hint: get(hObject,'Value') returns toggle state of togglebutton1

% --- Executes on button press in togglebutton2. function togglebutton2_Callback(hObject, eventdata, handles) yuchuli; % hObject handle to togglebutton2 (see GCBO) % eventdata reserved - to be defined in a future version of MATLAB % handles structure with handles and user data (see GUIDATA)

% Hint: get(hObject,'Value') returns toggle state of togglebutton2

% --- Executes on button press in togglebutton3. function togglebutton3_Callback(hObject, eventdata, handles) tezheng; % hObject handle to togglebutton3 (see GCBO) % eventdata reserved - to be defined in a future version of MATLAB % handles structure with handles and user data (see GUIDATA)

% Hint: get(hObject,'Value') returns toggle state of togglebutton3

% --- Executes when figure1 is resized. function figure1SizeChangedFcn(hObject, eventdata, handles) % hObject handle to figure1 (see GCBO) % eventdata reserved - to be defined in a future version of MATLAB % handles structure with handles and user data (see GUIDATA) if nargout [varargout{1:nargout}] = guimainfcn(guiState, varargin{:}); else guimainfcn(gui_State, varargin{:}); end % End initialization code - DO NOT EDIT

% --- Executes just before jidian is made visible. function jidian_OpeningFcn(hObject, eventdata, handles, varargin) % This function has no output args, see OutputFcn. % hObject handle to figure % eventdata reserved - to be defined in a future version of MATLAB % handles structure with handles and user data (see GUIDATA) % varargin command line arguments to jidian (see VARARGIN)

% Choose default command line output for jidian handles.output = hObject; ha=axes('units','normalized','position',[0 0 1 1]); uistack(ha,'down') II=imread('666.jpg'); image(II) colormap gray set(ha,'handlevisibility','off','visible','off');

axes(handles.axes1); axes(handles.axes2); axes(handles.axes3); axes(handles.axes4); axes(handles.axes5); axes(handles.axes6); % Update handles structure guidata(hObject, handles);

% UIWAIT makes jidian wait for user response (see UIRESUME) % uiwait(handles.figure1);

% --- Outputs from this function are returned to the command line. function varargout = jidian_OutputFcn(hObject, eventdata, handles) % varargout cell array for returning output args (see VARARGOUT); % hObject handle to figure % eventdata reserved - to be defined in a future version of MATLAB % handles structure with handles and user data (see GUIDATA)

% Get default command line output from handles structure varargout{1} = handles.output;

% --- Executes when figure1 is resized. function figure1_SizeChangedFcn(hObject, eventdata, handles) % hObject handle to figure1 (see GCBO) % eventdata reserved - to be defined in a future version of MATLAB % handles structure with handles and user data (see GUIDATA)

% --- Executes on button press in pushbutton1. function pushbutton1Callback(hObject, eventdata, handles) %%%%%把代码放到这,运行时自动加载 [filename,filepath]=uigetfile('C:\Users\dell\Desktop\信号处理课设-----杨硕\初始脉搏数据\MaiBobefore.txt'); filename=[filepath,filename]; [t,Plusepre]=textread(filename,'%f%f','headerlines',1);%读入2个浮点值,并跳过文档的第1行 [m,n]=size(Plusepre); n=3; s3=Plusepre;

%%%%%%%%%%%%—————提取2000个点进行数据处理——————%%%%%%%%%%%%%%%%%%%% fs=360;%采样率 x0=s3(1:2000);%取1到2000共2000个点 t=1:length(x0);%length(x0)指x0数组元素的个数 axes(handles.axes1); plot(t,x0) xlabel('采样点'); ylabel('magtitude'); title('标准脉搏信号') box1=msgbox('正在加载请稍候','提示'); %%%%%%%%%%%%%%%%%%%%%%%%%%%%初步去除基线漂移%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%中值滤波%%%%%%%%%%%%%%%%%%%%%%%%%%%% L1=medfilt1(x0,330); %一维中值滤波,x0为数组,即要处理原始波形,n是中值滤波器的参数,L1是滤波以后的结果(数组) L2=x0-L1; %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%频谱%%%%%%%%%%%%%%%%%%%%%%%% N=length(x0);%样点个数 df=fs/(N-1);%分辨率 f=(0:N-1)df;%其中每点的频率 Y=fft(L2(1:N))/N2;%真实的幅值 axes(handles.axes2); plot(f(1:N/2),abs(Y(1:N/2)));%傅里叶变换后的频谱图是对称的,这里需要一半就可以了 xlabel('频率/Hz'); ylabel('振幅'); axis ( [0 100 0 0.4] ); title('中值滤波后脉搏信号频率谱') drawnow; ```

三、运行结果

在这里插入图片描述\ 在这里插入图片描述\ 在这里插入图片描述\ 在这里插入图片描述\ 在这里插入图片描述\ 在这里插入图片描述

四、备注

版本:2014a

这篇关于【肌电信号】脉搏信号分析(去噪+特征提取)matlab 源码含GUI的文章就介绍到这儿,希望我们推荐的文章对编程师们有所帮助!



http://www.chinasem.cn/article/362350

相关文章

Redis主从/哨兵机制原理分析

《Redis主从/哨兵机制原理分析》本文介绍了Redis的主从复制和哨兵机制,主从复制实现了数据的热备份和负载均衡,而哨兵机制可以监控Redis集群,实现自动故障转移,哨兵机制通过监控、下线、选举和故... 目录一、主从复制1.1 什么是主从复制1.2 主从复制的作用1.3 主从复制原理1.3.1 全量复制

Redis主从复制的原理分析

《Redis主从复制的原理分析》Redis主从复制通过将数据镜像到多个从节点,实现高可用性和扩展性,主从复制包括初次全量同步和增量同步两个阶段,为优化复制性能,可以采用AOF持久化、调整复制超时时间、... 目录Redis主从复制的原理主从复制概述配置主从复制数据同步过程复制一致性与延迟故障转移机制监控与维

Redis连接失败:客户端IP不在白名单中的问题分析与解决方案

《Redis连接失败:客户端IP不在白名单中的问题分析与解决方案》在现代分布式系统中,Redis作为一种高性能的内存数据库,被广泛应用于缓存、消息队列、会话存储等场景,然而,在实际使用过程中,我们可能... 目录一、问题背景二、错误分析1. 错误信息解读2. 根本原因三、解决方案1. 将客户端IP添加到Re

Java汇编源码如何查看环境搭建

《Java汇编源码如何查看环境搭建》:本文主要介绍如何在IntelliJIDEA开发环境中搭建字节码和汇编环境,以便更好地进行代码调优和JVM学习,首先,介绍了如何配置IntelliJIDEA以方... 目录一、简介二、在IDEA开发环境中搭建汇编环境2.1 在IDEA中搭建字节码查看环境2.1.1 搭建步

Redis主从复制实现原理分析

《Redis主从复制实现原理分析》Redis主从复制通过Sync和CommandPropagate阶段实现数据同步,2.8版本后引入Psync指令,根据复制偏移量进行全量或部分同步,优化了数据传输效率... 目录Redis主DodMIK从复制实现原理实现原理Psync: 2.8版本后总结Redis主从复制实

锐捷和腾达哪个好? 两个品牌路由器对比分析

《锐捷和腾达哪个好?两个品牌路由器对比分析》在选择路由器时,Tenda和锐捷都是备受关注的品牌,各自有独特的产品特点和市场定位,选择哪个品牌的路由器更合适,实际上取决于你的具体需求和使用场景,我们从... 在选购路由器时,锐捷和腾达都是市场上备受关注的品牌,但它们的定位和特点却有所不同。锐捷更偏向企业级和专

无线路由器哪个品牌好用信号强? 口碑最好的三个路由器大比拼

《无线路由器哪个品牌好用信号强?口碑最好的三个路由器大比拼》不同品牌在信号覆盖、稳定性和易用性等方面各有特色,如何在众多选择中找到最适合自己的那款无线路由器呢?今天推荐三款路由器让你的网速起飞... 今天我们来聊聊那些让网速飞起来的路由器。在这个信息爆炸的时代,一个好路由器简直就是家庭网编程络的心脏。无论你

电脑显示hdmi无信号怎么办? 电脑显示器无信号的终极解决指南

《电脑显示hdmi无信号怎么办?电脑显示器无信号的终极解决指南》HDMI无信号的问题却让人头疼不已,遇到这种情况该怎么办?针对这种情况,我们可以采取一系列步骤来逐一排查并解决问题,以下是详细的方法... 无论你是试图为笔记本电脑设置多个显示器还是使用外部显示器,都可能会弹出“无HDMI信号”错误。此消息可能

Spring中Bean有关NullPointerException异常的原因分析

《Spring中Bean有关NullPointerException异常的原因分析》在Spring中使用@Autowired注解注入的bean不能在静态上下文中访问,否则会导致NullPointerE... 目录Spring中Bean有关NullPointerException异常的原因问题描述解决方案总结

python中的与时间相关的模块应用场景分析

《python中的与时间相关的模块应用场景分析》本文介绍了Python中与时间相关的几个重要模块:`time`、`datetime`、`calendar`、`timeit`、`pytz`和`dateu... 目录1. time 模块2. datetime 模块3. calendar 模块4. timeit