Skip to contents

This function creates input paths for floodam.agri simulations. It applies for extents in floodam.data::department, floodam.data::region or one of c("FRANCE MÉTROPOLITAINE", "FRANCE ENTIÈRE", "DOM")

Usage

prepare_input(
  extent,
  year,
  destination,
  include_national_2016 = TRUE,
  keep_extent_only = FALSE
)

Arguments

extent

character, name of departement, region or national scale. One of c("FRANCE MÉTROPOLITAINE", "FRANCE ENTIÈRE", "DOM")

year

character, year to be used.

destination

character, directory path where data is found.

include_national_2016

boolean, indicating whether to include national data used for the official damage functions in 2016 as backup. Default to TRUE.

keep_extent_only

boolean, indicating whether to perform the top_down choices or keep the specified extent only. Default to FALSE.

Value

named vector with input paths for floodam.agri

Examples

if (FALSE) { # \dontrun{
destination = tempdir()
input = prepare_input(
    extent = "FRANCE M\u00C9TROPOLITAINE",
    year = "2024",
    destination
)
print(input)

input = prepare_input(
    extent = "FRANCE M\u00C9TROPOLITAINE",
    year = "2024",
    destination,
    include_national_2016 = FALSE
)
print(input)
} # }