Convert data from minutes to hourly average

4 Ansichten (letzte 30 Tage)
Marina Minic
Marina Minic am 8 Okt. 2020
Kommentiert: Mohammad Sami am 8 Okt. 2020
My data has time set up as dd-month-yyyy hh:mm:ss How do I average my data from minutes to hours

Antworten (1)

Mohammad Sami
Mohammad Sami am 8 Okt. 2020
If your data is in timetable / table format. You can use the groupsummary to summarise your data into any intervals.
a = groupsummary(TT,"Column_w_datetime","hour","mean");
  2 Kommentare
Marina Minic
Marina Minic am 8 Okt. 2020
Thanks. In the answer you posted, do I just put "hour", or does that need to be replaced with something?
Mohammad Sami
Mohammad Sami am 8 Okt. 2020
Yes hour will provide hourly average. There are also other options if you want to change the interval.

Melden Sie sich an, um zu kommentieren.

Kategorien

Mehr zu Data Type Conversion finden Sie in Help Center und File Exchange

Community Treasure Hunt

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

Start Hunting!

Translated by