Interface with 'inputdlg'-MATLAB

4 次查看(过去 30 天)
I want to process a signal by applying a filter. I wanted the user to select the file and some filter parameters. For that I produced the following code, and the file selection does't work. Do you know any fuction that I can implement here to read the file?
SV1=uigetfile('*.mat','Select Input File'); %select the file
sampleRate = inputdlg('Select Sample Rate'); %select Sample Rate
lowEnd = inputdlg('Select lowEnd'); %select lowEnd
highEnd = inputdlg('Select highEnd'); %select highEnd
filterOrder = inputdlg('Select filterOrder');%select filterOrder
t_total1=floor(12288/sampleRate);
t1=(0:1/sampleRate:t_total1-(t_total1/12288))*1000;
O1_1 = SV1(:,9);
[b, a] = butter(filterOrder, [lowEnd highEnd]/(sampleRate/2)); % Generate filter coefficients
SSV1_1 = filtfilt(b, a, O1_1); %filtered signal
matlab filter parameters interface

回答(1 个)

Harsha Priya Daggubati
Hi,
What do you mean by fileselection is not working? I can see you are accessing 9th column from the file read, what is the issue you are facing?
'uigetfile' allows you to select files at a specified location. You can look at the following documentation page:

类别

Help CenterFile Exchange 中查找有关 Filter Banks 的更多信息

Community Treasure Hunt

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

Start Hunting!

Translated by