Skip to content

Commit

Permalink
Add map information and evaluation pages
Browse files Browse the repository at this point in the history
  • Loading branch information
jrfep committed Jul 4, 2024
1 parent a6a25df commit 4513f77
Show file tree
Hide file tree
Showing 7 changed files with 265 additions and 22 deletions.
10 changes: 9 additions & 1 deletion _quarto.yml
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,15 @@ website:
- href: efg-info.qmd
text: "Overview"
- text: "Map information"
href: map-info.qmd
menu:
- text: "Map evaluation"
href: map-evaluation.qmd
- text: "Current maps"
href: map-info.qmd
- text: "Version history"
href: map-version-history.qmd
- text: "Map updates"
href: map-updates.qmd
right:
- text: "How to..."
menu:
Expand Down
29 changes: 26 additions & 3 deletions about.qmd
Original file line number Diff line number Diff line change
@@ -1,9 +1,32 @@
---
title: "About"
title: "About this project"
author:
- name:
given: "José R."
family: "Ferrer-Paris"
email: j.ferrer@unsw.edu.au
orcid: 0000-0002-9554-3395
url: https://github.com/jrfep
affiliations:
- id: ces
name: Centre for Ecosystem Science, UNSW
city: Sydney
country: Australia
url: https://www.unsw.edu.au/research/ecosystem
- id: udash
name: UNSW Data Science Hub, UNSW
city: Sydney
country: Australia
url: https://www.unsw.edu.au/research/udash
- id: iucn
name: IUCN Commission on Ecosystem Management
city: Gland
country: Switzerland
url: https://www.iucn.org/our-union/commissions/group/iucn-cem-red-list-ecosystems-thematic-group
---

# Contact
This page is maintained by [José R. Ferrer-Paris](https://github.com/jrfep), [IUCN Red List of Ecosystems Science Team](https://github.com/red-list-ecosystem), [University of New South Wales, Australia](https://github.com/unsw-edu-au)
This page is maintained by José R. Ferrer-Paris on behalf of the [IUCN Red List of Ecosystems Science Team](https://github.com/red-list-ecosystem).

# Citation
This page is part of the publication:
Expand Down Expand Up @@ -61,7 +84,7 @@ Richard T. Kingsford

* [Context of the Global Ecosystem Typology](https://iucnrle.org/global-eco-typo)

* Keith, David A., Ferrer-Paris, José R., Nicholson, Emily, & Kingsford, Richard T. (2021). *Indicative distribution maps for Ecosystem Functional Groups - Level 3 of IUCN Global Ecosystem Typology (2.1.1)* [Data set]. **Zenodo**. [![DOI](https://zenodo.org/badge/DOI/10.5281/zenodo.5090419.svg)](https://doi.org/10.5281/zenodo.5090419)
* Keith, David A., Ferrer-Paris, José R., Nicholson, Emily, & Kingsford, Richard T. (2023). *Indicative distribution maps for Ecosystem Functional Groups - Level 3 of IUCN Global Ecosystem Typology (2.1.3)* [Data set]. **Zenodo**. [![DOI](https://zenodo.org/badge/DOI/10.5281/zenodo.3546513.svg)](https://doi.org/10.5281/zenodo.3546513){target='zenodo'}



9 changes: 9 additions & 0 deletions map-evaluation.qmd
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
---
title: "Map evaluation"
subtitle: "Information on map quality"
format: html
execute:
echo: false
---

We will add here information about map quality as evaluated by our expert's group.
54 changes: 38 additions & 16 deletions map-info.qmd
Original file line number Diff line number Diff line change
@@ -1,24 +1,46 @@
---
listing:
contents: map-info
type: table
categories: true
sort-ui: [title, subtitle]
fields: [title, subtitle]
field-display-names:
title: "Ecosystem functional group"
subtitle: "Biome"
sort:
- "subtitle"
- "title"
title: "Map information"
subtitle: "Current (valid) maps"
execute:
echo: false
warning: false
message: false
---

# Map information

## General notes on maps:
## General notes on maps

The maps in each profile show areas of the world containing major or minor occurrences of the ecosystem functional group. Minor occurrences are areas where an EFG is scattered in patches within matrices of others or where they occur in substantial areas but only within a segment of a larger region.

The maps were designed to be indicative of global distribution patterns and are not intended to represent fine-scale patterns. Given bounds of resolution and accuracy of source data, the maps should be used to query which EFG are likely to occur within areas, rather than which occur at particular point locations.

## List of maps
## List of maps

:::{.callout-tip}
## Valid maps
These links will show the current or valid maps for each functional group. Please check that the map code and version information matches the data you are using. If you are working with a different version of the map, you can look at the version history [here](map-version-history.qmd).
:::


```{r}
library(readxl)
library(dplyr)
library(readr)
library(DT)
library(stringr)
here::i_am("map-version-history.qmd")
out_folder <- here::here("gisdata", "profiles")
dest_file <- here::here(out_folder, "biome-names.csv")
biome_names <- read_csv(dest_file, show_col_types = FALSE) |>
rename("biome code" = "biome_code" , "biome name" = "name")
dest_file <- here::here(out_folder, "IUCN-GET-profiles-exported.xlsx")
profile_info <- read_excel(dest_file, sheet = 2) |>
left_join(biome_names, by = "biome code")
altmap_table <- profile_info |>
transmute(Biome = `biome name`, `Ecosystem functional group` = sprintf("<a href='map-info/%2$s_valid.html'>%1$s</a>", `name`, str_replace(`code`,"\\.", "_")))
DT::datatable(altmap_table, rownames = FALSE, escape = FALSE, filter = 'top',
options = list(dom = 'tpl', pageLength = 25))
```
135 changes: 135 additions & 0 deletions map-updates.qmd
Original file line number Diff line number Diff line change
@@ -0,0 +1,135 @@
---
title: "Map updates"
subtitle: "Priorities for map updates"
format: html
execute:
echo: false
---

As part of our data curation process we consider updates and improvements to all the maps. This is currently done in an irregular basis depending on time and resource availability.

We have set up some priorities for map development and updates, but we also consider issues raised by users. Please add your comments and suggestions using the dialogue boxes below each page, or go directly to our GitHub repository.


```{r}
#| message: false
#| warning: false
#library(ggplot2)
library(dplyr)
#library(DT)
#library(igraph)
#library(stringr)
#library(tidyr)
#library(lubridate)
library(RPostgreSQL)
# load("Map-evaluation-data.rda")
here::i_am("map-updates.qmd")
```

```{r}
#| message: false
#| warning: false
#| results: false
drv <- dbDriver("PostgreSQL") ## remember to update .pgpass file
con <- dbConnect(drv,
dbname = Sys.getenv("DBNAME"),
host = Sys.getenv("DBHOST"),
port = Sys.getenv("DBPORT"),
user = Sys.getenv("DBUSER"))
qry <- "
select license, count(*) as n
from map_evaluation
left join map_metadata USING(map_code,map_version)
where status = 'valid' and map_type = 'Indicative Map'
GROUP BY license;
"
maps_licenses <- dbGetQuery(con,qry)
qry <- "
SELECT license, evaluation[1] as evaluation, count(*) as N
FROM map_evaluation
LEFT JOIN map_metadata USING (map_code, map_version)
WHERE status = 'valid' AND map_type = 'Indicative Map'
GROUP BY license, evaluation
ORDER BY license, evaluation;
"
license_evaluation <- dbGetQuery(con,qry)
dbDisconnect(con)
```


## Checking dataset licenses

First we check the dataset licenses and aim to replace datasets that have any restrictions of use.

```{r}
license_evaluation_summary <-
license_evaluation |>
transmute(`datasets used` = case_when(
license %in% 'Non-commercial use' ~ "restricted use",
license %in% c(NA, 'Undocumented', 'See contact info') ~ "unclear/undocumented",
TRUE ~ "commercial use allowed"
),
`Evaluation` = case_when(
evaluation %in% c("Medium quality map", "Medium quality map series") ~ "Good enough",
evaluation %in% "Coarse quality map" ~ "Unsatisfactory",
evaluation %in% c("Fine quality map", "Fine quality map series") ~ "Best",
TRUE ~ evaluation
),
n
)
```

```{r}
license_evaluation_summary |>
group_by(`datasets used`) |>
summarise(total = sum(n), .groups = "drop") |>
knitr::kable()
```

## Improving quality

The second step is to review map quality as we aim to create higher quality maps with better overall evaluation:

```{r}
license_evaluation_summary |>
filter(`datasets used` %in% "commercial use allowed") |>
group_by(`Evaluation`) |>
summarise(total = sum(n), .groups = "drop") |>
knitr::kable()
```

## Next steps


```{mermaid}
%%| theme: forest
%%| label: priorities
%%| fig-cap: |
%%| Summary of license and evaluation of EFG maps to identify
%%| priorities for map updates.
flowchart TB
check1(["Check datasets used:\n license?"]):::checks
check2(["Check:\n - spatial resolution\n- validation\n- concept match\n(uncertainty)"]):::checks
step1(["Search\navailable/new\n datasets"]):::checks
ready(["Hurray!"]):::done
almostready([Best possible version\nflag any issues]):::done
classDef checks fill:#d0e9fa,stroke:#000
classDef steps fill:#d0d93a,stroke:#000
classDef done fill:#c6fc9c,stroke:#000
check1 -->|n=37 allows\ncommercial use| check2
check1 -->|n=62 restricted use| step1
check1 -.->|n=7 unclear/undocumented| step1
check2 -->|n=14 golden standard| ready
check2 -->|n=5 not perfect\nbut close enough| almostready
check2 -->|n=18 unsatisfactory| step1
```
44 changes: 44 additions & 0 deletions map-version-history.qmd
Original file line number Diff line number Diff line change
@@ -0,0 +1,44 @@
---
title: "Map version history"
execute:
echo: false
warning: false
message: false
---

## General notes on maps

The maps in each profile show areas of the world containing major or minor occurrences of the ecosystem functional group. Minor occurrences are areas where an EFG is scattered in patches within matrices of others or where they occur in substantial areas but only within a segment of a larger region.

The maps were designed to be indicative of global distribution patterns and are not intended to represent fine-scale patterns. Given bounds of resolution and accuracy of source data, the maps should be used to query which EFG are likely to occur within areas, rather than which occur at particular point locations.

## Version history

Please follow the links in the following table to review the version history for a particular functional group. You can filter by biome name or functional group name.

```{r}
library(readxl)
library(dplyr)
library(readr)
library(DT)
library(stringr)
here::i_am("map-version-history.qmd")
out_folder <- here::here("gisdata", "profiles")
dest_file <- here::here(out_folder, "biome-names.csv")
biome_names <- read_csv(dest_file, show_col_types = FALSE) |>
rename("biome code" = "biome_code" , "biome name" = "name")
dest_file <- here::here(out_folder, "IUCN-GET-profiles-exported.xlsx")
profile_info <- read_excel(dest_file, sheet = 2) |>
left_join(biome_names, by = "biome code")
altmap_table <- profile_info |>
transmute(Biome = `biome name`, `Ecosystem functional group` = name,
`Links` = sprintf("<a href='map-info/%1$s_valid.html'>Current version</a> / <a href='altmap-info/%1$s_history.html'>Version history</a>", str_replace(`code`,"\\.", "_")))
DT::datatable(altmap_table, rownames = FALSE, escape = FALSE, filter = 'top',
options = list(dom = 'tpl', pageLength = 25,
columnDefs = list(list(targets = 2, searchable = FALSE))
))
```
6 changes: 4 additions & 2 deletions profile-structure.qmd
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ The text describes key ecological traits diagnosed from literature and expert kn
Each profile is illustrated with a photograph that shows some of the ecological features mentioned in the text. Although representative examples were chosen for illustration, they may not represent the range of variability in features expressed within each functional group, some of which have extensive global distributions.
//-->

A workbook with profile content for Ecosystem Functional Groups of the IUCN Global Ecosystem Typology (Level 3 units) is available in an [OSF repository](https://osf.io/4dcea).
A workbook with profile content for Ecosystem Functional Groups of the IUCN Global Ecosystem Typology (Level 3 units) is available in an [OSF repository](https://osf.io/4dcea){target="OSF"}.

### Major ecosystem drivers

Expand All @@ -48,7 +48,9 @@ Maps are indicative of global distribution patterns are not intended to represen
We emphasise that spatial representation of Ecosystem Functional Groups does not follow higher-order groupings described in respective ecoregion classifications (provinces of Spalding 2007; major habitat types of Abell et al. 2008; biomes of Olsen et al. 2001 and Dinerstein et al. 2017). Consequently, when Ecosystem Functional Groups are aggregated into functional biomes (Level 2 of the Global Ecosystem Typology), spatial patterns may differ from those of biogeogreaphic biomes as mapped by Olsen et al (2001) and Dinerstein et al. (2017). Differences reflect the distinctions between functional and biogeographic interpretations of the term, “biome” (Mucina 2018).

Indicative maps are available in a data repository:
Keith, David A., Ferrer-Paris, Jose R., Nicholson, Emily, & Kingsford, Richard T. (eds.) (2020). Indicative distribution maps for Ecosystem Functional Groups - Level 3 of IUCN Global Ecosystem Typology (Version 2.1.1) [Data set]. Zenodo. DOI: [10.5281/zenodo.3546513](10.5281/zenodo.3546513)

Keith, David A., Ferrer-Paris, José R., Nicholson, Emily, & Kingsford, Richard T. (2023). *Indicative distribution maps for Ecosystem Functional Groups - Level 3 of IUCN Global Ecosystem Typology (2.1.3)* [Data set]. **Zenodo**. [![DOI](https://zenodo.org/badge/DOI/10.5281/zenodo.3546513.svg)](https://doi.org/10.5281/zenodo.3546513){target='zenodo'}


### References

Expand Down

0 comments on commit 4513f77

Please sign in to comment.