How to delete rows from a TimeSeries variable
조회 수: 9 (최근 30일)
이전 댓글 표시
Hello everyone,
I have a 1x1 double TimeSeries variable.
The size of both columns are 812997x1.
I want to exclude every rows indexed after and including the row number 664410.
How can I do it?
I've tried doing it like in a normal matrix but it obviously doesn't work:
HRTimeSeries.time(664410:end,:) = [ ];
댓글 수: 0
채택된 답변
dpb
2020년 3월 14일
편집: dpb
2020년 3월 14일
delsample
timeseries are different...only can address by the time values or events, not linear indexing. I've never found them helpful; use timetable or regular table instead for virtually any purpose unless the event feature is really suited for your specific purposes.
댓글 수: 2
dpb
2020년 3월 16일
That's pretty easy to write for the specific case, "not so much" if a row stuck down in the middle somewhere...
추가 답변 (0개)
참고 항목
카테고리
Help Center 및 File Exchange에서 Time Series에 대해 자세히 알아보기
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!