How to obtain hourly average from several years of data

2 ビュー (過去 30 日間)
Srilatha Raghavan
Srilatha Raghavan 2020 年 7 月 17 日
編集済み: KSSV 2023 年 9 月 11 日
Hello,
I have 7 years of hourly data(attached file). I have them in a timetable that has (7*8760 + extra hours from leap year) number of rows.
I am trying to find the average of each hour of the years. I have been exporting the table above to excel and then splittin it column wise and averaging and coming back to matlab and working on it. I tried the groupsummary function, but it gives me 24 hours of value.
I did find a previous answer to a similar question, but that was confusing to me as well. I have attached the link to that answer.
I would appreciate if someone could help me with this.
Thank you

採用された回答

Sindar
Sindar 2020 年 7 月 17 日
G = groupsummary(struct2table(WSHelp),'DateTime','hour','mean');
  7 件のコメント
Srilatha Raghavan
Srilatha Raghavan 2020 年 7 月 17 日
Oh yes! This works. Thank you so much! I appreciate your help :)
Sindar
Sindar 2020 年 7 月 17 日
Sorry, I had some typos, try the updated

サインインしてコメントする。

その他の回答 (0 件)

カテゴリ

Help Center および File ExchangeDates and Time についてさらに検索

Community Treasure Hunt

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

Start Hunting!

Translated by