Azzera filtri
Azzera filtri

how aggregate duraration and sum it in timetable

2 visualizzazioni (ultimi 30 giorni)
Hi,
it's a timetable and i want to sum all duration equal:
example:
04/01/2010 2202 1.23
05/01/2010 2202 1.26
......
i want this:
duration value
22:02 2.49 (1.23+1.26)

Risposta accettata

the cyclist
the cyclist il 27 Mag 2024
Modificato: the cyclist il 27 Mag 2024
Here is one way:
load("matlab_tt2")
TT2.timeOfDay = timeofday(TT2.datt);
equalDurationSum = groupsummary(TT2,"timeOfDay","sum")
equalDurationSum = 657x3 table
timeOfDay GroupCount sum_close1 _________ __________ __________ 00:01:00 3 3542 00:02:00 3 3542.2 00:03:00 2 2370.8 00:04:00 3 3542 00:05:00 2 2357.5 00:06:00 2 2357.5 00:07:00 2 2357.8 00:08:00 2 2370.8 00:09:00 2 2357.5 00:10:00 2 2357.2 00:11:00 3 3541.2 00:12:00 3 3541.5 00:13:00 2 2357.5 00:14:00 2 2357.8 00:15:00 3 3542 00:16:00 3 3542

Più risposte (0)

Categorie

Scopri di più su Timetables 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!

Translated by