How to get mean of every 3 raster files and so on from 576 raster files in R?

I have 16 years NDVI data set with 576 tiff files (36 files per year) with 10-days temporal resolution. I need monthly NDVI data. so for this I have to get mean of every 3 raster files and so on upto 576 files in R. What is the best r code for this?

Looking forward!
Thanks

This topic was automatically closed 21 days after the last reply. New replies are no longer allowed.