The Analogues R-Package - Ramirez-Villegas


Published on

Presentation by Julian Ramirez-Villegas.

CCAFS workshop titled "Using Climate Scenarios and Analogues for Designing Adaptation Strategies in Agriculture," 19-23 September in Kathmandu, Nepal.

Published in: Technology
1 Like
  • Be the first to comment

No Downloads
Total views
On SlideShare
From Embeds
Number of Embeds
Embeds 0
No embeds

No notes for slide

The Analogues R-Package - Ramirez-Villegas

  1. 1. The Analogues R-Package<br />Julian Ramirez-Villegas<br />
  2. 2. The tool<br />Entirely coded as an package<br />Optimised for large datasets with GRASS-GIS (experimental)<br />Example data at 0.5-degree (~100km), globally, for 24 GCMs, and the SRES-A1B emission scenario, but any other data can be integrated<br />Implemented using the raster, rgdal, sp, and maptoolspackages, so that it is easy to handle GIS formats, and export outputs<br />Dissimilarity is calculated via two measures (CCAFS and Hallegatte), and uncertainty is provided as the SD and CV among individual GCMs, but, R is flexible<br />Calculations can be done and outputs generated for any geographic region at any resolution.<br />
  3. 3. What do you need?Set up: just download and install<br />R >= 2.13.0 (, and packages:<br />raster, sp, rgdal, maps, spgrass6, stringr, maptools, foreign, lattice, akima, plotrix, rimage, XML<br />GRASS GIS >= 6.4 ( (exp)<br />Quantum GIS >= 1.6 ( (opt)<br />
  4. 4. What do you need?Set up: just download and install<br /><br />
  5. 5. Analogues of what?<br /><ul><li>Of a site within all land areas of a given geographic domain (gridded dissimilarity)</li></li></ul><li>Gridded analyses Inputs/Outputs<br />
  6. 6. Initial set up: climate data<br />Climate data for gridded analyses<br /><ul><li>Must be gridded data (rasters)
  7. 7. At least one variable, for a given area, with any time-step (from whole year to daily)
  8. 8. Is uniform in spatial coverage (i.e. extent) and resolution
  9. 9. Represents one or more given (climate) scenario(s)
  10. 10. Is stored in the same folder
  11. 11. Is named in a way the tool can understand
  12. 12. Is in a GIS format supported by GDAL (Geographic Data Abstraction Library)</li></li></ul><li>We provide some data<br />Periods: 2030(2020_2049)<br />Extent: Global<br />Emissions scenario: SRES-A1B (a1b)<br />Naming structure: <br />[CURRENT]_[DTR | MEAN | PREC | BIO]_[STEP].ASC<br />[SRES]_[YEAR]_[GCM]_[DTR | TMEAN | PREC | BIO]_[STEP].ASC<br />Resolution: 0.5 degree (~50km)<br /><ul><li> But we also have 1km downscaled datasets for the same GCMs and for SRES-A2, SRES-B1 and SRES-A1B itself ( </li></li></ul><li>We provide some data<br />
  13. 13. We provide some data<br />For instance: BCCR-BCM2.0, precipitation<br />
  14. 14. Gridded-analyses: creating a basic report<br />After an analysis, you could print a simple report showing results<br />
  15. 15. Point-based analyses Inputs/Outputs<br />Similar to gridded, but not equal!<br />
  16. 16. Initial set up: climate data<br />Climate data for point analyses<br /><ul><li>Can be in any format, but you need to load them into R (as matrices) beforehand
  17. 17. Ensure quality and zero NODATA by yourself beforehand
  18. 18. One matrix per variable, with columns being time-steps and rows sites
  19. 19. Objects named in R as [VARIABLE].[SCENARIO]
  20. 20. Uniform in time-step for all variables</li></li></ul><li>Point analyses: using R afterwards<br />If you know how to use R, you could do your further data analyses with it<br />Dissimilarity from a site in Ghana (future) to 35 other sites at present<br />(bars are the distribution of 24 GCMs)<br />
  21. 21. In both cases…<br /><ul><li>Results can be exported from R in any GIS (gridded) or table (points) format
  22. 22. Further operations can be done in R, upon your needs and knowledge
  23. 23. The R-workspace can be saved and then loaded at any time in the future</li>