VeruGHub / easyclimate

Easy access to high-resolution daily climate data for Europe
https://verughub.github.io/easyclimate/
GNU General Public License v3.0
45 stars 1 forks source link

Calculating climate indicators and bioclimatic variables: use CRAN standard packages? #11

Closed Pakillo closed 2 years ago

Pakillo commented 3 years ago

Hi,

I just uploaded a functional version of the package. We can now extract daily data for point coordinates as well as polygons (including the ability to summarise values within polygons, e.g. mean, min, max, etc). The output can be either a dataframe or a raster (most useful for plotting). See get_daily_climate

I think the package might be quite complete by now (except vignettes, adding more tests, etc). But there was a second set of functions aimed at aggregating daily values into monthly or annual values, and calculating several climatic indicators (degree days etc).

Aggregating daily into monthly or annual data should be quite straightforward now as the data are provided in tidy (long) format. But I think we should definitely include these functions (ideally using base R rather than tidyverse)

For climate indicators I think we should rather exploit standard CRAN packages like https://cran.r-project.org/web/packages/ClimInd/index.html, https://www.r-pkg.org/pkg/climdex.pcic, https://www.r-pkg.org/pkg/agroclim, https://cran.rstudio.com/web/packages/fruclimadapt/fruclimadapt.pdf, https://cran.rstudio.com/web/packages/chillR/chillR.pdf, etc. That is, I think we should not write this functionality again. Only ensure our output data can be used with these packages, and maybe only write functions for indicators or variables not available on CRAN, if any.

VeruGHub commented 3 years ago

Thanks, @Pakillo. As we talked, for now I will prepare a vignette to show a set of climatic variables that can be calculated with the data downloaded with easyclimate, by using other packages or tidyverse-based functions. If someone else in the team wants to work in the R base functions is more than welcome.