Transforms the metadata of a Camera Trap Data Package to an EML file that can be uploaded to a GBIF IPT for publication.
Usage
write_eml(
package,
directory = ".",
title = package$title,
description = package$description,
creators = NULL,
keywords = c("camera traps")
)
Arguments
- package
A Camtrap DP, as read by
read_camtrap_dp()
.- directory
Path to local directory to write file to. If
NULL
, then the EML object is returned instead, which can be useful for extended/adapting the EML before writing withEML::write_eml()
.- title
Dataset title.
- description
Dataset description. Will be added after an automatically generated paragraph. Multiple paragraphs can be provided as a character vector.
- creators
Dataset creators
If
NULL
then allpackage$contributors
will be added as creators, in the order as listed.If e.g.
c("Emma Cartuyvels", "Jim Casaer", "...", "Peter Desmet")
, then Emma Cartuyvels, Jim Casaer and Peter Desmet will be set as first, second and last creators respectively, on the condition that their name (title
) is present inpackage$contributors
. All other contributors will be inserted at"..."
, sorted on their last name.
- keywords
Dataset keywords.
Transformation details
Metadata is derived from what is provided in package
and in the function
parameters.
The following properties are set:
title: Title as provided in
title
orpackage$title
.description: Description as provided in
description
orpackage$description
. The description is preceded by an automatically generated paragraph describing from which project and platform the dataset is derived, and to which extend coordinates are rounded (package$coordinatePrecision
).license: License with scope
data
as provided inpackage$licenses
.creators: Contributors (all roles) as provided in
package$contributors
, filtered/reordered based oncreators
.contact: First creator.
metadata provider: First creator.
keywords: Keywords as provided in
keywords
.associated parties: Organizations as provided in
package$organizations
.geographic coverage: Bounding box as provided in
package$spatial
.taxonomic coverage: Species (no other ranks) as provided in
package$taxonomic
.temporal coverage: Date range as provided in
package$temporal
.project data: Title, acronym as identifier, description, and sampling design as provided in
package$project
. The first creator is set as project personnel.alternative identifier: Identifier as provided in
package$id
. If this is a DOI, no new DOI will be created when publishing to GBIF.external link: URL of the project as provided in
package$project$path
.
To be set manually in the GBIF IPT: type, subtype, update frequency and publishing organization.
Not set: sampling methods and citations.
Not applicable: collection data.
See also
Other publication functions:
round_coordinates()
,
write_dwc()