フィルターのクリア

Calculating hourly average over several days using retime

3 ビュー (過去 30 日間)
Nao
Nao 2022 年 11 月 12 日
回答済み: Image Analyst 2022 年 11 月 12 日
Hello.
I have a temperature data over the course of 2 weeks, at a sampling rate of 1 sec. I want to calculate the hourly average so that I can see a tendency in temperature change within the day.
I have tried this so far:
TT = array2timetable(TempC,"RowTimes",T);
Hour = retime(TT,"hourly","mean");
but this gives me the outcome of average temperature of the hour of one day, such as:
'2022/06/18 11:00:00' 32.2
'2022/06/18 12:00:00' 31.7
'2022/06/18 13:00:00' 30.8
'2022/06/18 14:00:00' 31.4
My ideal outcome is hourly average of 2 weeks combined. For example, I want the calculations to take average of the temperature at 12pm on June 18, 19, 20,..., so that the final result will show something like 12pm 30℃, 1pm 32℃,...
How should I do this? Thank you in advance!

回答 (1 件)

Image Analyst
Image Analyst 2022 年 11 月 12 日

カテゴリ

Help Center および File ExchangeTimetables についてさらに検索

製品

Community Treasure Hunt

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

Start Hunting!

Translated by