Counting bin and averaging using retime to include all of my data
조회 수: 5 (최근 30일)
이전 댓글 표시
I have a question about the reptime function. I'm trying to count a redistributed data every 24 hr, from a data set that is taken every minute.
TT2 = retime(TT1, 'daily', 'count');
"retime" starts counting 24 hours from the first row. The question that I have is that my data set in TT1 does not have complete 24 hour data set at the end, so when I use 'count' the number of points in the last data bit is lower than in TT1.
How can I use retime on all the data set from TT1?
댓글 수: 2
Akira Agata
2017년 9월 6일
retime starts counting 24 hours from 00:00:00 of the day in the 1st row, and the total count is equal to the number of row of the input timetable, as shown below. Please tell us more detail of the problem you are facing (attaching .mat file would be quite helpful!).
% Sample timetable
Time = datetime({'2015-12-18 07:02:12';'2015-12-18 08:00:47';...
'2015-12-18 09:01:37';'2015-12-18 10:03:10';...
'2015-12-19 02:59:34'});
Temp = [37.3;41.9;45.7;42.3;39.8];
Pressure = [30.1;29.9;30.03;29.9;29.8];
TT = timetable(Time,Temp,Pressure);
retime(TT,'daily','count')
답변 (0개)
참고 항목
카테고리
Help Center 및 File Exchange에서 Timetables에 대해 자세히 알아보기
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!