Hello! I have 750+ rasters with precipitation data. The folder contains a raster for each month for the years 1945-2009. I need to find the mean of each year in a new raster. However, I am getting caught up on how to parse all the rasters with the specific years in their name. I am only able to run the calcs on one year at a time. The rasters are named like Oct2009.tif, Nov2009.tif, Nov2008.tif, etc.
# Define input workspace and create list of rasters
arcpy.env.workspace = r'C:\Users\dzelmanfahm\Desktop\DEM_Trials'
rasters = arcpy.ListRasters("*2009*")
# Run cell statistics
calc = arcpy.sa.CellStatistics(rasters, statistics_type = "MEAN")