Set up various parameters needed by many of the data extraction and plotting functions

Set up shared parameters for extraction and plotting functions.

get_params(start_date, end_date, input_file, var_names)

get_params(start_date, end_date, input_file, var_names)

Arguments

start_date

The date from which to start data extraction.

end_date

The end date of the data extraction request.

input_file

The URI or filename from which to extract data.

var_names

A list of eReefs variable names for which to extract data.

Value

list of parameter values that includes: input_file, the input filename, after transformation by substitute_filename() ereefs_case, information about the format of the input file, as output by get)ereefs_case() input_stem, the 'stem' of the filename in case the parent function needs to dynamically calculate filenames from an example netcdf filename. start_date, start_date transformed to a date-time object start_day, the day of the month in start_date start_tod, the time of day in start_date (0.5 if not given) start_month, the integer month of the yr in start_date start_yr, the integer yr in start_date end_date, end_date transformed to a date-time object end_day, the day of the month in end_date end_tod, the time of day in end_date (0.5 if not given) end_month, the integer month of the yr in end_date end_yr, the integer yr in end_date mths, a vector of months for which to extract data yrs, a vector of yrs for which to extract data var_list, a list of variable names in var_names ereefs_origin, the origin date specified for Julian dates in the netcdf file (assumed to be 1990-01-01 if not specified) ds, a date-time vector for extracted data julian_date, the time vector in the raw format provided in the netcdf file spatial_grid, a tibble containing the grid latitudes and longitudes

A named list of parameters used by higher-level package functions.