Can I average a retime?
Ältere Kommentare anzeigen
I have data that is measured every second for 60 minutes.
My current code is
newtimetable3 = retime(TT3,'regular','nearest','TimeStep',seconds(60))
This code retimes the data to every minute which is nice, but I am trying to retime the data to where it averages within the minute for 20 minutes.
Alll in all, I need help making the code averge the times within the 60 seconds and marks that number per minute.
3 Kommentare
jonas
am 15 Jul. 2020
Not sure I understand what you want to do.. This would be the arguments for average minutes:
TT_new = retime(TT,'minutely', 'mean')
However, guessing this is not it?
Mohammad Sami
am 16 Jul. 2020
Use minutes(20) instead for 20 minutes.
ZH
am 17 Jul. 2020
Antworten (1)
Walter Roberson
am 16 Jul. 2020
TT3_20 = TT3(1:60*20);
newtimetable3_20 = retime(TT3_20, 'regular', 'minutely', 'TimeStep', 1);
Kategorien
Mehr zu MATLAB finden Sie in Hilfe-Center und File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!