latitude_longitude_cwp_manipulation: Conversion function for latitude, longitude and cwp item

View source: R/latitude_longitude_cwp_manipulation.R

latitude_longitude_cwp_manipulationR Documentation

Conversion function for latitude, longitude and cwp item

Description

Conversion function for latitude, longitude and cwp item. For more information on the cwp format check the online document on https://www.fao.org/cwp-on-fishery-statistics/handbook/general-concepts/main-water-areas/en/#c737533.

Usage

latitude_longitude_cwp_manipulation(
  manipulation_process,
  data_longitude = NULL,
  data_latitude = NULL,
  data_cwp = NULL,
  referential_grid_file_path,
  output_degree_format = NULL,
  output_degree_parameter = NULL,
  input_degree_format = NULL,
  epsg_code = as.integer(4326)
)

Arguments

manipulation_process

character expected. A string matching one of the accepted processes. Available processes are "cwp_to_latitude_longitude" or "latitude_longitude_to_cwp".

data_longitude

character expected. By default NULL. Mandatory argument for "latitude_longitude_to_cwp" process. A string vector with longitude value(s). Formats allowed is decimal degree (with point separator) or in degree minute seconde format (xxdxx'xx”). If values are duplicated, the function simplify the process automatically (no need to remove them before).

data_latitude

character expected. By default NULL. Mandatory argument for "latitude_longitude_to_cwp" process. A string vector with latitude value(s). Formats allowed is decimal degree (with point separator) or in degree minute seconde format (xxdxx'xx”). If values are duplicated, the function simplify the process automatically (no need to remove them before).

data_cwp

character expected. By default NULL. Mandatory argument for "cwp_to_latitude_longitude" process. A string vector with cwp value(s).

referential_grid_file_path

character expected. File path of the referential grid shape. File with .Rdata extension file expected.

output_degree_format

character expected. By default NULL. Mandatory for "cwp_to_latitude_longitude" process. A string matching one of the accepted output degree format. Available formats are "degree_minute_seconde" and "decimal_degree".

output_degree_parameter

character expected. By default NULL. Mandatory for "cwp_to_latitude_longitude" process. You can choose between "centroid" or "corner" for display coordinates of the square according to the centroid or the corner of it.

input_degree_format

character expected. By default NULL. Mandatory for "latitude_longitude_to_cwp" process. A string matching one of the accepted output degree format. Available formats are "degree_minute_seconde" and "decimal_degree".

epsg_code

integer expected. By default 4326. Mandatory for "latitude_longitude_to_cwp" process. An integer (on 4 digits) of one EPSG spatial reference systems related to latitude and longitude coordinates provide. Check this web site for more informations: https://www.spatialreference.org. By default 4326.

Value

Return a tibble.


OB7-IRD/furdeb documentation built on April 21, 2024, 12:17 a.m.