csv data to fft in matlab
71 visualizaciones (últimos 30 días)
Mostrar comentarios más antiguos
Kyong Sun Bae
el 5 de Dic. de 2021
Comentada: Kyong Sun Bae
el 5 de Dic. de 2021
this 1_20mhz.csv data is time domain signal
one of vector means time and the last one is Voltage of the signal
i want to change this csv data to fft in matlab
(time, voltage) -> (frequency , magnitude)
0 comentarios
Respuesta aceptada
Chunru
el 5 de Dic. de 2021
Editada: Chunru
el 5 de Dic. de 2021
x = readmatrix("1_20mhz.csv");
n = size(x, 1);
fs = 1/diff(x(1:2)) % sampling frequency
y = fft(x(:,2));
f = (0:n-1)/n*fs;
%plot(f, abs(y))
plot(f/1e6, 20*log10(abs(y)))
xlabel('f(MHz)'); ylabel('Amp (dB)'); grid on
xlim([1.9 20])
4 comentarios
Más respuestas (0)
Ver también
Categorías
Más información sobre Parametric Spectral Estimation en Help Center y File Exchange.
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!