Skip to content

Commit 7033baf

Browse files
committed
- new data: rscd_stats
- documentation: fix typos
1 parent d79e896 commit 7033baf

30 files changed

+111
-56
lines changed

.Rbuildignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6,3 +6,4 @@
66
^data-raw$
77
^dev$
88
^devtools_history\.R$
9+
^\.github$

.gitattributes

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
*.arrow filter=lfs diff=lfs merge=lfs -text

DESCRIPTION

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
Package: resourcecodedata
22
Title: Data package with the Resourcecode database configuration data
3-
Version: 0.1.0
3+
Version: 0.2.0
44
Authors@R:
55
person("Nicolas", "Raillard", , "nicolas.raillard@ifremer.fr", role = c("aut", "cre"),
66
comment = c(ORCID = "0000-0003-3385-5104"))
@@ -18,9 +18,11 @@ BugReports:
1818
https://github.com/Resourcecode-project/r-resourcecodedata/issues
1919
Depends:
2020
R (>= 3.5)
21+
Suggests:
22+
resourcecode
2123
Encoding: UTF-8
2224
LazyData: true
2325
LazyDataCompression: bzip2
2426
NeedsCompilation: no
2527
Roxygen: list(markdown = TRUE)
26-
RoxygenNote: 7.3.1
28+
RoxygenNote: 7.3.2

NEWS.md

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,10 @@
1+
# resourcecodedata 0.2.0
2+
3+
Add statistics computed on the FIELD grid, on the whole period of time. See `?rscd_stats`
4+
for more details about available statistics.
5+
6+
# resourcecodedata 0.1.0
7+
8+
Initial release with database configuration file and some examples:
9+
- sea-state parameters time series;
10+
- 1D and 2D spectra.

R/data.R

Lines changed: 33 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -3,8 +3,7 @@
33
#' This data contains the location and characteristics of the 328,030 nodes
44
#' where the RESOURCECODE hindcast data is available
55
#'
6-
#' @format ## `rscd_field`
7-
#' A data frame with 328,030 rows and 5 columns:
6+
#' @format A data frame with 328,030 rows and 5 columns:
87
#' \describe{
98
#' \item{node}{node number}
109
#' \item{longitude, latitude}{coordinates of the nodes}
@@ -21,8 +20,7 @@
2120
#' This data contains the location and characteristics of the 24,276 nodes
2221
#' where the full 2D spectral data is available in the RESOURCECODE data.
2322
#'
24-
#' @format ## `rscd_spectral`
25-
#' A data frame with 24,276 rows and 5 columns:
23+
#' @format A data frame with 24,276 rows and 5 columns:
2624
#' \describe{
2725
#' \item{longitude, latitude}{coordinates of the nodes}
2826
#' \item{name}{Name of the spectral output point}
@@ -37,8 +35,7 @@
3735
#'
3836
#' This data contains the variables available in the FIELD database.
3937
#'
40-
#' @format ## `rscd_variables`
41-
#' A data frame with 88 rows and 3 columns:
38+
#' @format A data frame with 88 rows and 3 columns:
4239
#' \describe{
4340
#' \item{name}{short name of the variable}
4441
#' \item{longname}{Full name}
@@ -53,8 +50,7 @@
5350
#' This data contains the coastline used to run the RESOURCECODE hindcast.
5451
#' This will be mainly used for ploting purpose.
5552
#'
56-
#' @format ## `rscd_coastline`
57-
#' A data frame with 24403 rows and 3 columns:
53+
#' @format A data frame with 24403 rows and 3 columns:
5854
#' \describe{
5955
#' \item{longitude,latitude}{coordinates of the border line}
6056
#' \item{depth}{depth of the border.}
@@ -69,8 +65,7 @@
6965
#' RESOURCECODE hindcast, as data separated from the mainland.
7066
#' This will be mainly used for ploting purpose.
7167
#'
72-
#' @format ## `rscd_islands`
73-
#' A data frame with 24403 rows and 3 columns:
68+
#' @format A data frame with 24403 rows and 3 columns:
7469
#' \describe{
7570
#' \item{longitude,latitude}{coordinates of the border line}
7671
#' \item{depth}{depth of the border}
@@ -85,8 +80,7 @@
8580
#' This data contains the triangles of the unstructured computational mesh.
8681
#' This will be mainly used for ploting purpose.
8782
#'
88-
#' @format ## `rscd_triangles`
89-
#' A matrix with 3 rows and 566506 columns:
83+
#' @format A matrix with 3 rows and 566506 columns:
9084
#' \describe{
9185
#' \item{rows}{verticies of the triangles}
9286
#' \item{columns}{node number of each vertices}
@@ -100,8 +94,7 @@
10094
#' The wave spectrum discretization considers 36 frequencies, starting from
10195
#' 0.0339 Hz up to 0.9526 Hz with a frequency increment factor of 1.1
10296
#'
103-
#' @format ## `rscd_freq`
104-
#' An array 36 elements with the frequencies values
97+
#' @format A vector 36 elements with the frequencies values
10598
#'
10699
#' @source User Manual of the RESOURCECODE database
107100
#' <https://archimer.ifremer.fr/doc/00751/86306/>
@@ -112,8 +105,7 @@
112105
# In terms of directional discretization, 36 directions were used
113106
#' (equivalent to a directional resolution of 10°;
114107
#'
115-
#' @format ## `rscd_dir`
116-
#' An array of length 36 with the directionnal bins
108+
#' @format A vector of length 36 with the directionnal bins
117109
#'
118110
#' @source User Manual of the RESOURCECODE database
119111
#' <https://archimer.ifremer.fr/doc/00751/86306/>
@@ -126,8 +118,7 @@
126118
#' data at the 'Pierre noires (6200069) wave buoy from
127119
#' 01-01-1994 to 31-01-1994.
128120
#'
129-
#' @format ## `rscd_1d_spectra`
130-
#' A list with 12 elements:
121+
#' @format A list with 12 elements:
131122
#' \describe{
132123
#' \item{longitude}{Longitude}
133124
#' \item{latitude}{Latitude}
@@ -170,8 +161,7 @@
170161
#' data at the 'Pierre noires (6200069) wave buoy from
171162
#' 01-01-1994 to 31-01-1994.
172163
#'
173-
#' @format ## `rscd_2d_spectra`
174-
#' A list with 9 elements:
164+
#' @format A list with 9 elements:
175165
#' \describe{
176166
#' \item{longitude}{Longitude}
177167
#' \item{latitude}{Latitude}
@@ -199,3 +189,26 @@
199189
#' @source User Manual of the RESOURCECODE database
200190
#' <https://archimer.ifremer.fr/doc/00751/86306/>
201191
"rscd_2d_spectra"
192+
193+
#' Resourcecode statistical summary
194+
#'
195+
# Example of summary statistics computed on the FIELD grid,
196+
#' on the whole period covered by the database, currently 1994-2023.
197+
#'
198+
#' @format A data.frame with columns:
199+
#' \describe{
200+
#' \item{hs_mean}{Mean significant wave height}
201+
#' \item{hs_max}{Maximal modeled significant wave height}
202+
#' \item{tp_mean}{Mean peak wave period}
203+
#' \item{wind_speed_mean}{Mean wind speed at 10m height}
204+
#' \item{wind_speed_max}{Maximal wind speed at 10m height}
205+
#' \item{cur_speed_mean}{Mean current speed at surface}
206+
#' \item{cur_speed_max}{Maximal surface current speed at surface}
207+
#' \item{Wave_Dp_MeanDir}{Mean wave direction from Dp (direction of mean vector)}
208+
#' \item{Wind_MeanDir}{Mean wind direction at 10m height (direction of mean vector)}
209+
#' \item{Cur_MeanDir}{Mean surface current direction (direction of mean vector)}
210+
#' }
211+
#' @source User Manual of the RESOURCECODE database
212+
#' <https://archimer.ifremer.fr/doc/00751/86306/> and computations
213+
#' made by Nicolas Raillard on original netCDF files.
214+
"rscd_stats"

data-raw/coastline.arrow

-367 KB
Binary file not shown.

data-raw/grid_FIELD.arrow

-5.8 MB
Binary file not shown.

data-raw/grid_SPEC.arrow

-942 KB
Binary file not shown.

data-raw/islands.arrow

-1.03 MB
Binary file not shown.

0 commit comments

Comments
 (0)