Filter table data into matrix

2 ビュー (過去 30 日間)
Annymm
Annymm 2020 年 10 月 1 日
回答済み: Eric Sofen 2020 年 10 月 2 日
I have rainfall amount data by month for seveeral years and different weather stations. I want to filter the data for May, June July into a new table. How can I do that? My table looks like this:
Date Georgetown Kamarang Lethem Mabaruma NewAmsterdam Timehri
1971-01 120 146.3000 195.6000 227.4000
1971-02 78.9000 82.8000 31.9000 68.8000
1971-03 80.2000 65.1000 15.3000 111.5000
1971-04 126.8000 173.2000 28.1000 178.3000
1971-05 374.6000 271 150.6000 411.3000
1971-06 401.2000 479.1000 505.3000
1971-07 296.6000 320.9000 317 243.5000
1971-08 347.7000 249.1000 227.8000 189.6000 348.4000
1971-09 108.4000 190.9000 104.9000 228.1000 123.1000

回答 (1 件)

Eric Sofen
Eric Sofen 2020 年 10 月 2 日
From your description, it sounds like you want data for MJJ for all years? Assuming your data is in a timetable and your dates are represented as datetime:
t(ismember(month(t.Date), [5:7]),:)

カテゴリ

Help Center および File ExchangeWeather and Atmospheric Science についてさらに検索

タグ

Community Treasure Hunt

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

Start Hunting!

Translated by