How can I retime my timetable with a 10days timestep?

조회 수: 23(최근 30일)
Hamed Hedayatnia
Hamed Hedayatnia 2020년 5월 1일
댓글: Peter Perkins 2020년 5월 5일
Hi guys,
I need to retime my hourly timetable to an average 10days time step. Then apply an index to them.
I know that predefine timesteps like hourly or monthly exist in m,atlab but 10day time interval??
Thanks in advance

채택된 답변

dpb 2020년 5월 1일
Read the documentation...
TT2 = retime(TT1,'regular',method,'TimeStep',dt) calculates regularly spaced row times using the time step dt. The dt input argument is a scalar duration or calendar duration, specifying a time step of any size. The row times of TT2 span the range of row times of TT1.
Use this syntax when the time step is not one of the predefined time steps you can specify as a character vector or string.
  댓글 수: 5
Peter Perkins
Peter Perkins 2020년 5월 5일
A rare misstep indeed!

댓글을 달려면 로그인하십시오.

추가 답변(1개)

Steven Lord
Steven Lord 2020년 5월 1일
Pass a datetime vector as the newTimes input to retime as shown in the Interpolate Timetable Data to Time Vector example on the documentation page.





Community Treasure Hunt

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

Start Hunting!

Translated by