|
1 | 1 | #' Workflow for GeoPressureR |
2 | 2 | #' |
3 | 3 | #' @description |
4 | | -#' The `geopressuretemplate` function manages the complete workflow for modeling bird trajectories |
5 | | -#' using geospatial pressure and light data. It includes the creation of tag data, likelihood map |
6 | | -#' computation (pressure and/or light), graph model construction, trajectory estimation, and |
7 | | -#' pressure path computation. The function follows a standard structure as defined by the GitHub |
8 | | -#' repository [geopressuretemplate](https://github.com/Rafnuss/GeoPressureTemplate), which |
9 | | -#' separates data and analysis for improved readability, sharability, and reproducibility. |
10 | | -#' |
11 | | -#' @param id A unique identifier for the tag being processed. |
12 | | -#' @param config A configuration object specifying workflow parameters, which is loaded by default |
13 | | -#' using `config::get(config = id)`. |
14 | | -#' @param quiet Logical. If `TRUE`, suppresses informational messages during execution. The default |
15 | | -#' value is `FALSE`. |
16 | | -#' @param file A file path to save the intermediate results (e.g., tag, graph, and pressure paths). |
17 | | -#' Default is `./data/interim/{id}.RData`. |
18 | | -#' @param assert_graph Logical. If `TRUE`, check that the config is compatible for the creation of |
19 | | -#' a graph. The default value is `TRUE`. Set to `FALSE` only if you don't want to create a graph |
20 | | -#' model |
21 | | -#' @param ... Additional parameters to overwrite default or config values. Always prefer to modify |
22 | | -#' `config.yml` if possible. |
| 4 | +#' The `geopressuretemplate()` function manages the complete workflow for modelling bird |
| 5 | +#' trajectories using geolocator data. It includes the creation `tag` object, the construction of |
| 6 | +#' the likelihood maps (pressure and/or light), the creation of the graph model construction, and, |
| 7 | +#' finally, the estimation of the trajectory products and the pressure path computation. Read the |
| 8 | +#' [Workflow chapter in the GeoPressureManual |
| 9 | +#' ](https://raphaelnussbaumer.com/GeoPressureManual/geopressuretemplate-workflow.html) for more |
| 10 | +#' information. |
| 11 | +#' |
| 12 | +#' To be able to run successfully these function, you will need to have correctly set-up the data |
| 13 | +#' and configuration files according following the [GeoPressureTemplate standard |
| 14 | +#' ](https://raphaelnussbaumer.com/GeoPressureManual/geopressuretemplate-project.html). |
| 15 | +#' |
23 | 16 | #' |
24 | 17 | #' @details |
25 | 18 | #' The `geopressuretemplate` function is a high-level entry point that coordinates multiple |
26 | | -#' steps for processing geospatial animal movement data. It relies on underlying child |
| 19 | +#' steps for processing the geolocator data and produce trajectories. It relies on underlying child |
27 | 20 | #' functions for each step: |
28 | 21 | #' |
29 | 22 | #' * **Tag Creation [`geopressuretemplate_tag()`]**: Initializes and labels the `tag` object. It |
|
67 | 60 | #' Each of these child functions can be called individually or automatically as part of |
68 | 61 | #' the `geopressuretemplate` workflow. |
69 | 62 | #' |
| 63 | +#' @param id unique identifier of a tag. |
| 64 | +#' @param config configuration object specifying workflow parameters, which is loaded by default |
| 65 | +#' using `config::get(config = id)`. |
| 66 | +#' @param quiet Logical. If `TRUE`, suppresses informational messages during execution. The default |
| 67 | +#' value is `FALSE`. |
| 68 | +#' @param file A file path to save the intermediate results (e.g., tag, graph, and pressure paths). |
| 69 | +#' Default is `./data/interim/{id}.RData`. |
| 70 | +#' @param assert_graph Logical. If `TRUE`, check that the config is compatible for the creation of |
| 71 | +#' a graph. The default value is `TRUE`. Set to `FALSE` only if you don't want to create a graph |
| 72 | +#' model |
| 73 | +#' @param ... Additional parameters to overwrite default or config values. Always prefer to modify |
| 74 | +#' `config.yml` if possible. |
| 75 | +#' |
70 | 76 | #' |
71 | 77 | #' @return |
72 | 78 | #' The function returns nothing. Instead, it saves the processed outputs (tag, graph, |
|
75 | 81 | #' @examples |
76 | 82 | #' \dontrun{ |
77 | 83 | #' # Run the complete geopressuretemplate workflow |
78 | | -#' geopressuretemplate("18LX", quiet = TRUE) |
| 84 | +#' geopressuretemplate("18LX") |
| 85 | +#' |
| 86 | +#' # Or run step-by-step |
| 87 | +#' # you can check that all the parameters are correctly set in the config file |
| 88 | +#' geopressuretemplate_config(id) |
| 89 | +#' # 1. creation of the tag |
| 90 | +#' tag <- geopressuretemplate_tag("18LX") |
| 91 | +#' # 2. creation of the graph |
| 92 | +#' geopressuretemplate_graph("18LX") |
| 93 | +#' # 3. Computation of the pressurepath |
| 94 | +#' geopressuretemplate_pressurepath("18LX") |
79 | 95 | #' } |
80 | 96 | #' |
81 | 97 | #' @family geopressuretemplate |
| 98 | +#' @seealso [GeoPressureManual |
| 99 | +#' ](https://raphaelnussbaumer.com/GeoPressureManual/geopressuretemplate-workflow.html) |
82 | 100 | #' @export |
83 | 101 | geopressuretemplate <- function( |
84 | 102 | id, |
|
0 commit comments