time for 50 events

조회 수: 1 (최근 30일)
Seemab  Janjua
Seemab Janjua 2015년 12월 8일
답변: Ingrid 2015년 12월 8일
i have data with fields Year Month Day Hour Min Sec(data file is attached also).i want to find elapsed time of 50 events in days in such a way that t50-t1, t100-t51, t150,t101 etc...
  댓글 수: 1
the cyclist
the cyclist 2015년 12월 8일
Can you be more specific by what you mean by "elapsed time"? What is the calculation?
Also, do you already have these data loaded into the MATLAB workspace? If so, how are they stored (e.g. are they in a matrix already, or in a cell array with the header, etc)?

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

채택된 답변

Ingrid
Ingrid 2015년 12월 8일
if you have the data in matrix format you could do this
timeVector = datenum(data(:,1:6));
timeVectorEvery50 = timeVector(1:50:end);
timeInDaysBetweenEvents = diff(timeVectorEvery50);

추가 답변 (0개)

카테고리

Help CenterFile Exchange에서 Time Series Events에 대해 자세히 알아보기

Community Treasure Hunt

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

Start Hunting!

Translated by