Removing Leap day from my timetable

4 ビュー (過去 30 日間)
Hamed Hedayatnia
Hamed Hedayatnia 2020 年 4 月 28 日
コメント済み: Adam Danz 2020 年 4 月 28 日
I need to remove leap days of all years from my timetable. I mean all values belong to 29 feb. my timetable is a hourly time table.
  1 件のコメント
Adam Danz
Adam Danz 2020 年 4 月 28 日
That data you attached does not contain a timetable or any kind of datatime data.

サインインしてコメントする。

採用された回答

Adam Danz
Adam Danz 2020 年 4 月 28 日
TT is the timetable and TT.Time is the time column.
isLeapDay is a logical vector identiying the rows of TT that belong to a leap day.
isLeapDay = month(TT.Time)==2 & day(TT.Time)==29;
TT(isLeapDay,:) = []; % remove leap days.
  8 件のコメント
Hamed Hedayatnia
Hamed Hedayatnia 2020 年 4 月 28 日
Thanks Adam, I applied it in anouther file and it works great.
Adam Danz
Adam Danz 2020 年 4 月 28 日
Sounds like you worked it out! Glad I could help.

サインインしてコメントする。

その他の回答 (0 件)

カテゴリ

Help Center および File ExchangeData Type Identification についてさらに検索

製品

Community Treasure Hunt

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

Start Hunting!

Translated by