How to average Bimonthly into monthly and yearly?
1 次查看(过去 30 天)
显示 更早的评论
Hi Everyone,
Please, I have Bimonthly images for 37 years. (1982-2018). I need your help to create a code to average Bimonthly data into monthly and yearly. Please, look at the following data:
'1982_01_15a.n07-VI3g.tif'
'1982_01_15b.n07-VI3g.tif'
'1982_02_15a.n07-VI3g.tif'
'1982_02_15b.n07-VI3g.tif'
'1982_03_15a.n07-VI3g.tif'
'1982_03_15b.n07-VI3g.tif'
'1982_04_15a.n07-VI3g.tif'
'1982_04_15b.n07-VI3g.tif'
'1982_05_15a.n07-VI3g.tif'
'1982_05_15b.n07-VI3g.tif'
'1982_06_15a.n07-VI3g.tif'
'1982_06_15b.n07-VI3g.tif'
'1982_07_15a.n07-VI3g.tif'
'1982_07_15b.n07-VI3g.tif'
'1982_08_15a.n07-VI3g.tif'
'1982_08_15b.n07-VI3g.tif'
'1982_09_15a.n07-VI3g.tif'
'1982_09_15b.n07-VI3g.tif'
'1982_10_15a.n07-VI3g.tif'
'1982_10_15b.n07-VI3g.tif'
'1982_11_15a.n07-VI3g.tif'
'1982_11_15b.n07-VI3g.tif'
'1982_12_15a.n07-VI3g.tif'
'1982_12_15b.n07-VI3g.tif'
.
.
.
.
'2018_12_15a.n07-VI3g.tif'
'2018_12_15b.n07-VI3g.tif'
Thank you in advance
Reyadh
0 个评论
回答(1 个)
Bjorn Gustavsson
2019-6-21
Tips: have a look at the dir, for function and keyword repsectively. Presumably you have some function for reading your .tif-files, but those two constructs should get you going.
HTH
4 个评论
Bjorn Gustavsson
2019-6-25
I could, but in the long run it is better if you do it yourself. Take the task step-by-step. You know that you can have nested loops, and that you can use index-variables that you can increment anywhere you want, you know how many months there is in a year. You can do this!
另请参阅
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!