how can i smooth this plot?

3 visualizaciones (últimos 30 días)
Jose Sandoval
Jose Sandoval el 9 de Oct. de 2017
Comentada: Kh zaa el 16 de Sept. de 2018
Regards, I have this curve that I show in the screen capture, but its tendency is very scattered I would like to know if there is the possibility of approaching it to a graph of the linear type by means of a filter
thank you very much
attached the data

Respuesta aceptada

Star Strider
Star Strider el 9 de Oct. de 2017
You have broadband noise. There may be a signal at about 0.35 Hz.
The Fourier transform analysis:
D = xlsread('power.xls');
t = D(:,1);
p = D(:,2);
L = length(t);
Ts = mean(diff(t)); % Sampling Interval (sec)
Fs = 1/Ts; % Sampling Frequency (Hz)
Fn = Fs/2; % Nyquist Frequency (Hz)
FT_p = fft(p - mean(p))/L; % Fourier Transform (Discrete)
Fv = linspace(0, 1, fix(length(t)/2)+1)*Fn; % Frequency Vector
Iv = 1:length(Fv); % Index Vector
figure(1)
plot(Fv, abs(FT_p(Iv))*2)
grid
I will leave it for you to sort this.
  1 comentario
Kh zaa
Kh zaa el 16 de Sept. de 2018
I use level-1 s-function in my simulink model. Measurements of 5 variables are collected in simulink and sent to s-function. In order to filter out some of measurements noise, i need to use the average of the snapshots received over a a time window (i.e. 2 second). how i can do that ? thanks

Iniciar sesión para comentar.

Más respuestas (0)

Etiquetas

Community Treasure Hunt

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

Start Hunting!

Translated by