A global mapping analysis of 6 local reef potential pressure layers
Results from this analysis are available as a scientific article: Andrello, M., Darling, E. S., Wenger, A., Suárez-Castro, A. F., Gelfand, S., & Ahmadia, G. N. (2022). A global map of human pressures on tropical coral reefs. Conservation Letters, Early view, e12858. https://doi.org/10.1111/conl.12858
BCU Report cards/
Contains the individual report cards (pdf), one for each of the 83 refugia (aka Bioclimatic Units: BCUs).
data-raw/
Contains the original data layers.
data-raw/Read_layers.R
Code to
data/allreefs
layer.You do not need to run this script if you are only interested in the final results or if you want to extract values for new sites.
data/
Contains the final GIS layers of the 6 local reef pressures and the global climatic scores of Beyer et al. (2018), in three different formats:
.shp
, to open with ArcGIS).GPKG
(to open with QGis).sql
(in .zip
, to open with a PostGIS database).RData
(with R)In R, type data(allreefs)
to load the dataset.
key.xlsx
contains correspondence between field names of the RData and GPKG files, on one hand, the the ESRI file, on the other hand
data/report-cards/
:Contains data to produce the individual report cards, one for each of the 83 refugia.
R/
Contains some scripts to generate the report cards and extract the data from the data layers giving point coordinates. In particular:
extract_values.R
. Function to extract pressure values for a set of coordinates provided by the user. This is useful if you want to know the values of the six pressures for new sites. To see the documentation for this function, please load the code with devtools::load_all()
and then look at the help file via ?extract_values
.analysis/
Contains all the scripts needed to reproduce the results and the figures of the article.
Analysis.R
. Code to:
Analysis BCU medians.R
. Code to:
Post-treatment.R
. Code to:
Plot Maps.R
. Code to
Sednut.R
. Code to
analysis/report-cards/
contains the code to produce the report cards, which are saved in BCU Report cards/
.
Run data-raw/read_layers.R
to create the final GIS layers in data/
from the six original layers stored in data-raw/
. Beware that treatment of the raster layers (coastal population and tourism) takes a long time to run.
Figure | Script
--- | ---
Figure 1 | analysis/Plot Maps.R
(first part)
Figure 2 | analysis/Plot Maps.R
(second part)
Figure 3 | analysis/Analysis.R
Figure 4 | analysis/Analysis.R
Supplementary Figure 1 | analysis/Analysis.R
Supplementary Figure 2 to 7 | analysis/Plot Maps.R
(second part)
Supplementary Figure 9 | analysis/Analysis.R
Supplementary Figure 10 | analysis/Analysis.R
Supplementary Figure 11 | analysis/Analysis BCU medians.R
Supplementary Figure 12 | analysis/Analysis BCU medians.R
Supplementary Figure 13 | data-raw/Read_layers.R
Supplementary Figure 14 | analysis/Analysis.R
Supplementary Figure 15 | analysis/Sednut.R
Please note that Supplementary Figure 8 was made with QGis and annotated in Power Point, there is no R code to produce it
Run analysis/Analysis BCU medians.R
.
Use the function extract_values.R
on a list of points with longitude and latitude. To see the documentation for this function, please load the code with devtools::load_all()
and then look at the help file via ?extract_values
.
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.