I am working on climate change impacts on hydrology. I am using Rstudio for data analysis. I have a daily precipitation data (resolution 10km x 10km) for a catchment (catchment area is around 57000 Km^2) from 1981-2010 in NetCDF file. I want to calculate average daily data for the period 1981-2010 for each grid.
The NetCDF file has 1 variable (precipitation) and 3 dimensions (longitude, latitude and time).
Could you please suggest me scripts/functions that can be used for this purpose!
If you get stuck and want more detailed help you should work on making a "reprex" (reproducible example) including a small bit of your data and the R code that you have tried. Read up on this here:
I haven't worked with netCDF files ... but:
The documentation at http://geog.uoregon.edu/bartlein/courses/geog607/Rmd/netCDF_01.htm
shows how a 'slice' of a raster 'brick' (3-D array) can be extracted into a dataframe suitable for processing and graphing with other tools (e.g. dplyr and ggplot). Presumably then, multiple slices can be 'stacked' into a long-form dataframe to capture all the information.