Hourly averages over a 20yr time series
5 visualizzazioni (ultimi 30 giorni)
Mostra commenti meno recenti
Hi,
I have a 20yr time series of data with time values for each hour, so ~175,000 time values. I want to calculate an hourly mean for the time series, so for example on Jan 1st at 00:00:00, I will have 20 values at this time over the 20 year series and I would like to calculate the mean, and so on for each date and time. The date and time values are formatted as '01-Jan-2000 00:00:00'.
2 Commenti
Steven Lord
il 10 Mar 2021
To clarify, the first "bin" of your data would take the mean of data from the following dates and times in your time series?
dt = datetime(2000:2020, 1, 1, 0, 0, 0, 'Format', 'dd-MMM-yyyy HH:mm:ss')
And the next bin would have data from:
dt = datetime(2000:2020, 1, 1, 1, 0, 0)
and so on and so forth?
Risposte (2)
Sargondjani
il 10 Mar 2021
Its not exactly clear over which values you want to calculate the mean, but have a look at this function, that can calculate moving averages:
https://uk.mathworks.com/help/matlab/ref/movmean.html
0 Commenti
Vedere anche
Categorie
Scopri di più su Dates and Time in Help Center e File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!