adapt.geo_sirene.Rd
The following treatment are performed:
Only some fileds are selected, field names (colnames) are consistently set.
NA values are consistently set.
Type of fields are consistently set, some checks are performed on transformations.
Data set is cut and saved by departments
Only observations with spatial coordinates are kept.
Exposition of observations (belonging or not to eaip) is added.
adapt.geo_sirene(
origin,
destination,
archive,
export = "fst",
scheme = floodam.data::scheme_sirene_2019,
na_value = floodam.data::scheme_sirene_na,
eaip_path = NULL,
projection = 4326,
order_by = c("state", "eaip"),
retrieve = FALSE,
verbose = FALSE
)
character, path to the directory where archive are stored
character, path to the directory where results should be saved
character, vector of archive to be adpated
character, option for export format of the results
data.frame, how archive variables should be treated
data.frame, list of NA values for each variables
character, path where eaip archives should be find
optional numeric, 4 digits projection to use
optional character, name of the variable to sort the output data. Default sorting is by state and eaip (if added).
logical, should the result be returned
logical, should the function give some sumup informations.
if retrieve = TRUE, data.frame of adapated data stored in archive.
if (FALSE) {
origin = ""
destination = tempdir()
archive = "geo_siret_34.csv.gz"
result = adapt.geo_sirene(origin, destination, verbose = TRUE, retrieve = TRUE)
}