Interface with 'inputdlg'-MATLAB

2 views (last 30 days)
Margarida Chiote
Margarida Chiote on 13 Jun 2020
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

Answers (1)

Harsha Priya Daggubati
Harsha Priya Daggubati on 16 Jun 2020
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:

Categories

Find more on Filter Banks in Help Center and File Exchange

Community Treasure Hunt

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

Start Hunting!