I Have a time series data , containing time, position and error in three column , I want to get the power spectral density of the time series containg the error

1 view (last 30 days)
The sample time series is like the following:
Time position error
2005.10822 4.09605 0.00205
2005.11096 4.09587 0.00210
2005.11370 4.09601 0.00209
2005.11644 4.09531 0.00246
2005.11918 4.09960 0.00272
2005.12192 4.09812 0.00217
2005.12466 4.09808 0.00219
2005.12740 4.09878 0.00229
2005.13014 4.09790 0.00275
2005.13287 4.09803 0.00238
2005.13561 4.10136 0.00278
2005.13835 4.09995 0.00310
2005.14109 4.09727 0.00245
2005.14383 4.09690 0.00228
2005.14657 4.09782 0.00231
2005.14931 4.09842 0.00229

Accepted Answer

Wayne King
Wayne King on 1 Oct 2012
Edited: Wayne King on 1 Oct 2012
I'll assume that X is your matrix with 3 columns and the 3rd column is the error vector.
errvec = X(:,3);
% if you have the Signal Processing Toolbox
Pxx = periodogram(errvec,rectwin(length(errvec)));
plot(10*log10(Pxx))
If you do not have the Signal Processing Toolbox, write back and let me know the length of the error vector (how many elements).
By the way if you are just trying to determine whether the error vector is white noise, I think there are better ways than using the PSD estimate. For an white noise assessment using the cross correlation:

More Answers (0)

Categories

Find more on Startup and Shutdown 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!