df <- tibble::tibble(
scientificName = c("Crinia Signifera", "Crinia Signifera", "Litoria peronii"),
latitude = c(-35.27, -35.24, -35.83),
longitude = c(149.33, 149.34, 149.34),
eventDate = c("2010-10-14", "2010-10-14", "2010-10-14"),
countryCode = c("AU", "AU", "AU"),
state = c("New South Wales", "New South Wales", "New South Wales"),
locality = c("Melville Caves", "Melville Caves", "Bryans Swamp about 3km away")
)
# Reformat columns to Darwin Core Standard terms
df |>
set_locality(
countryCode = countryCode,
stateProvince = state,
locality = locality
)
# Columns with valid Darwin Core terms as names are automatically detected
# and checked. This will do the same as above.
df |>
set_locality(
stateProvince = state
)
Run the code above in your browser using DataLab