Skip to content

Commit

Permalink
Merge pull request #105 from b-cubed-eu/h2
Browse files Browse the repository at this point in the history
Start headings at h2
  • Loading branch information
wlangera authored Dec 9, 2024
2 parents c780b2b + cabdeca commit 9347126
Show file tree
Hide file tree
Showing 11 changed files with 60 additions and 36 deletions.
4 changes: 2 additions & 2 deletions .zenodo.json
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
{
"title": "gcube: Simulating Biodiversity Data Cubes",
"version": "1.1.0",
"version": "1.1.1",
"license": "MIT",
"upload_type": "software",
"description": "<p>Simulation framework for biodiversity data cubes.<\/p>",
"description": "<p>This R package provides a simulation framework for biodiversity data cubes. This can start from simulating multiple species distributed in a landscape over a temporal scope. In a second phase, the simulation of a variety of observation processes and effort can generate actual occurrence datasets. Based on their (simulated) spatial uncertainty, occurrences can then be designated to a grid to form a data cube.<\/p>",
"keywords": [
"simulation",
"data cubes",
Expand Down
13 changes: 10 additions & 3 deletions CITATION.cff
Original file line number Diff line number Diff line change
Expand Up @@ -17,12 +17,19 @@ contact:
family-names: Langeraert
affiliation: Research Institute for Nature and Forest (INBO)
orcid: 0000-0002-5900-8109
doi: ~
doi: 10.5281/zenodo.14038996
license: MIT
repository-code: https://github.com/b-cubed-eu/gcube/
type: software
abstract: "Simulation framework for biodiversity data cubes."
abstract: "This R package provides a simulation framework for biodiversity data cubes.
This can start from simulating multiple species distributed in a landscape over
a temporal scope. In a second phase, the simulation of a variety of observation
processes and effort can generate actual occurrence datasets. Based on their (simulated)
spatial uncertainty, occurrences can then be designated to a grid to form a data
cube."
identifiers:
- type: doi
value: 10.5281/zenodo.14038996
- type: url
value: https://b-cubed-eu.github.io/gcube/
version: 1.1.0
version: 1.1.1
13 changes: 10 additions & 3 deletions DESCRIPTION
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
Package: gcube
Title: Simulating Biodiversity Data Cubes
Version: 1.1.0
Version: 1.1.1
Authors@R: c(
person("Ward", "Langeraert", , "ward.langeraert@inbo.be", role = c("aut", "cre"),
comment = c(ORCID = "0000-0002-5900-8109", affiliation = "Research Institute for Nature and Forest (INBO)")),
Expand Down Expand Up @@ -33,10 +33,17 @@ Authors@R: c(
person("Research Institute for Nature and Forest (INBO)", , , "info@inbo.be", role = "cph"),
person("European Union's Horizon Europe Research and Innovation Programme (ID No 101059592)", role = "fnd")
)
Description: Simulation framework for biodiversity data cubes.
Description: This R package provides a simulation framework for
biodiversity data cubes. This can start from simulating multiple
species distributed in a landscape over a temporal scope. In a second
phase, the simulation of a variety of observation processes and effort
can generate actual occurrence datasets. Based on their (simulated)
spatial uncertainty, occurrences can then be designated to a grid to
form a data cube.
License: MIT + file LICENSE
URL: https://github.com/b-cubed-eu/gcube,
https://b-cubed-eu.github.io/gcube/
https://b-cubed-eu.github.io/gcube/,
https://doi.org/10.5281/zenodo.14038996
BugReports: https://github.com/b-cubed-eu/gcube/issues
Imports:
assertthat,
Expand Down
6 changes: 6 additions & 0 deletions NEWS.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,9 @@
# gcube 1.1.1

* Add more elaborate package description #102.
* Uniform naming of articles and start headings at h2 #103.
* Add DOI to citation file #104.

# gcube 1.1.0

* Publish release on Zenodo.
Expand Down
2 changes: 1 addition & 1 deletion _pkgdown.yml
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ articles:
- articles/grid-designation-process
- title: "Multi-species approach"
contents:
- articles/multi_species_approach
- articles/multi-species-approach

reference:
- title: "Core gcube workflow functions"
Expand Down
19 changes: 11 additions & 8 deletions codemeta.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,19 +2,19 @@
"@context": "https://doi.org/10.5063/schema/codemeta-2.0",
"@type": "SoftwareSourceCode",
"identifier": "gcube",
"description": "Simulation framework for biodiversity data cubes.",
"description": "gcube is an R package that provides a simulation framework for biodiversity data cubes. This can start from simulating multiple species distributed in a landscape over a temporal scope. In a second phase, the simulation of a variety of observation processes and effort can generate actual occurrence datasets. Based on their (simulated) spatial uncertainty, occurrences can then be designated to a grid to form a data cube.",
"name": "gcube: Simulating Biodiversity Data Cubes",
"relatedLink": "https://b-cubed-eu.github.io/gcube/",
"relatedLink": ["https://b-cubed-eu.github.io/gcube/", "https://doi.org/10.5281/zenodo.14038996"],
"codeRepository": "https://github.com/b-cubed-eu/gcube",
"issueTracker": "https://github.com/b-cubed-eu/gcube/issues",
"license": "https://spdx.org/licenses/MIT",
"version": "1.1.0",
"version": "1.1.1",
"programmingLanguage": {
"@type": "ComputerLanguage",
"name": "R",
"url": "https://r-project.org"
},
"runtimePlatform": "R version 4.4.1 (2024-06-14 ucrt)",
"runtimePlatform": "R version 4.4.2 (2024-10-31 ucrt)",
"author": [
{
"@type": "Person",
Expand Down Expand Up @@ -334,7 +334,7 @@
},
"SystemRequirements": null
},
"fileSize": "557.447KB",
"fileSize": "558.437KB",
"citation": [
{
"@type": "SoftwareSourceCode",
Expand All @@ -346,13 +346,16 @@
"familyName": "Langeraert"
}
},
"name": "gcube: Simulating Biodiversity Data Cubes. Version 1.1.0",
"url": "https://b-cubed-eu.github.io/gcube/"
"name": "gcube: Simulating Biodiversity Data Cubes. Version 1.1.1",
"identifier": "10.5281/zenodo.14038996",
"url": "https://b-cubed-eu.github.io/gcube/",
"@id": "https://doi.org/10.5281/zenodo.14038996",
"sameAs": "https://doi.org/10.5281/zenodo.14038996"
}
],
"releaseNotes": "https://github.com/b-cubed-eu/gcube/blob/master/NEWS.md",
"readme": "https://github.com/b-cubed-eu/gcube/blob/main/README.md",
"contIntegration": ["https://github.com/b-cubed-eu/gcube/actions/workflows/check_on_different_r_os.yml", "https://app.codecov.io/gh/b-cubed-eu/gcube/"],
"developmentStatus": "https://www.repostatus.org/#active",
"keywords": ["r", "r-package"]
"keywords": ["r", "r-package", "biodiversity-informatics", "data-cubes", "simulations"]
}
7 changes: 4 additions & 3 deletions inst/CITATION
Original file line number Diff line number Diff line change
Expand Up @@ -2,12 +2,13 @@ citHeader("To cite `gcube` in publications please use:")
# begin checklist entry
bibentry(
bibtype = "Manual",
title = "gcube: Simulating Biodiversity Data Cubes. Version 1.1.0",
title = "gcube: Simulating Biodiversity Data Cubes. Version 1.1.1",
author = c( author = c(person(given = "Ward", family = "Langeraert"))),
year = 2024,
url = "https://b-cubed-eu.github.io/gcube/",
abstract = "Simulation framework for biodiversity data cubes.",
textVersion = "Langeraert, Ward (2024) gcube: Simulating Biodiversity Data Cubes. Version 1.1.0. https://b-cubed-eu.github.io/gcube/",
abstract = "This R package provides a simulation framework for biodiversity data cubes. This can start from simulating multiple species distributed in a landscape over a temporal scope. In a second phase, the simulation of a variety of observation processes and effort can generate actual occurrence datasets. Based on their (simulated) spatial uncertainty, occurrences can then be designated to a grid to form a data cube.",
textVersion = "Langeraert, Ward (2024) gcube: Simulating Biodiversity Data Cubes. Version 1.1.1. https://b-cubed-eu.github.io/gcube/",
keywords = "simulation; data cubes; B-Cubed; biodiversity; Monte-Carlo",
doi = "10.5281/zenodo.14038996",
)
# end checklist entry
8 changes: 4 additions & 4 deletions vignettes/articles/detection-process.Rmd
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ library(dplyr) # data wrangling
library(ggplot2) # data visualisation
```

# Input
## Input

The functions are set up such that a single polygon as input is enough to go through this workflow using default arguments.
The user can change these arguments to allow for more flexibility.
Expand Down Expand Up @@ -77,7 +77,7 @@ ggplot() +
theme_minimal()
```

# Detect occurrences
## Detect occurrences

We have our occurrences, but not all occurrences are generally observed.
The detection of occurrences depends on the detection probability of a species
Expand Down Expand Up @@ -214,7 +214,7 @@ ggplot() +
theme_minimal()
```

# Example
## Example

Now that we know how the supporting functions work, we can simulate the detection process using the `sample_observations()` function.
We can for example state that our species has a 0.9 detection probability and this time we say there is a very small chance to detect it on the road.
Expand Down Expand Up @@ -246,7 +246,7 @@ ggplot() +
theme_minimal()
```

# Adding coordinate uncertainty
## Adding coordinate uncertainty

To mimic real life data collection, we can finally add coordinate uncertainty to our observations.
We only keep the detected occurrences of the previous example.
Expand Down
6 changes: 3 additions & 3 deletions vignettes/articles/grid-designation-process.Rmd
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ library(ggplot2) # data visualisation
library(ggExtra) # enhance data visualisation
```

# Input
## Input

The functions are set up such that a single polygon as input is enough to go through this workflow using default arguments.

Expand Down Expand Up @@ -173,7 +173,7 @@ ggplot() +
theme_minimal()
```

# Grid designation
## Grid designation

Now we can make a data cube from our observations while taking into account the uncertainty.
We can create the grid using the `grid_designation()` function.
Expand Down Expand Up @@ -319,7 +319,7 @@ ggExtra::ggMarginal(scatter_normal, type = "histogram")

If no coordinate uncertainty is provided, the original observation point is used for grid designation.

# Example
## Example

Now we know how to use the randomisation in `grid_designation()`.
By default we use uniform randomisation.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ library(dplyr) # data wrangling
library(ggplot2) # data visualisation
```

# Spatial extend
## Spatial extend

As input, we create a polygon in which we simulate occurrences.
It represents the spatial extend of the species.
Expand Down Expand Up @@ -99,7 +99,7 @@ ggplot() +
theme_minimal()
```

# Input dataframe
## Input dataframe

To generate cubes for multiple species efficiently, we create a dataframe where each row represents a different species and where we specify all arguments to be used by the main cube simulation functions, viz `simulate_occurrences()`, `sample_observations()`, `filter_observations()`, `add_coordinate_uncertainty()`, and `grid_designation()`, in separate columns.
The values within these columns can change between species.
Expand Down Expand Up @@ -177,7 +177,7 @@ multi_species_dataset2 <- generate_taxonomy(
identical(multi_species_dataset1, multi_species_dataset2)
```

# Mapping the simulation process over each row/species
## Mapping the simulation process over each row/species

Each cube simulation function has a mapping companion.
These mapping functions apply the single-species operations for each row using the `purrr::pmap()` strategy.
Expand Down Expand Up @@ -298,7 +298,7 @@ map_occ_cube_df3 <- multi_species_dataset2_renamed %>%
glimpse(map_occ_cube_df3)
```

# Visualise examples
## Visualise examples

Let's visualise the output for two of the six species.

Expand Down
10 changes: 5 additions & 5 deletions vignettes/articles/occurrence-process.Rmd
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ library(ggplot2) # data visualisation
library(tidyterra) # visualisation spatraster objects
```

# Input
## Input

The functions are set up such that a single polygon as input is enough to go through this workflow using default arguments.
The user can change these arguments to allow for more flexibility.
Expand All @@ -53,7 +53,7 @@ ggplot() +
theme_minimal()
```

# Simulate occurrences
## Simulate occurrences

We generate occurrence points within the polygon using the `simulate_occurrences()` function.
Default arguments ensure that an sf object with POLYGON geometry is sufficient to simulate occurrences.
Expand All @@ -64,7 +64,7 @@ Default arguments ensure that an sf object with POLYGON geometry is sufficient t

The options for user defined arguments are demonstrated in the next subsections.

## Changing number of occurrences over time
### Changing number of occurrences over time

Say we want to have 100 occurrences in our plot over 10 years.
You can change the trend in the average number of occurrences over time.
Expand Down Expand Up @@ -192,7 +192,7 @@ tibble(
theme_minimal()
```

## Changing the degree of spatial clustering
### Changing the degree of spatial clustering

We can also choose the amount of spatial clustering.
We visualise this with the supporting functions used in `simulate_occurrences()`.
Expand Down Expand Up @@ -317,7 +317,7 @@ ggplot() +
theme_minimal()
```

# Example
## Example

Now that we know how the supporting functions work, we can generate occurrence points within the polygon using the `simulate_occurrences()` function.
We can for example sample randomly within the polygon over 6 time points were we use a random walk over time with an initial average number of occurrences equal to 100.
Expand Down

0 comments on commit 9347126

Please sign in to comment.