View source: R/atlantis_hydro.R
create_transport | R Documentation |
Transport is the hydrodynamic forcing for the Atlantis model from oceanographic models. These functions aim to minimize the amount of manual handling of details, creating an NetCDF file that can be modified directly. All the Box Geometry Model details are determined from the bgm file itself. The output file is the precursor file for input to HydroConstruct (as per section 4.1 of the Atlantis User Guide).
create_transport(
filename,
model_title = "Transport file [placeholder]",
bgmfilepath = "",
bgmlevels = NULL,
time_steps = NULL,
transp_params = "",
overwrite = FALSE
)
filename |
the NetCDF file to create |
model_title |
name of the model |
bgmfilepath |
path to BGM file |
bgmlevels |
the Atlantis depth levels |
time_steps |
actual time steps, need to be regularly space |
transp_params |
optional details to put in the NetCDF notes |
overwrite |
set to |
Please use the original BGM file in its native map projection, there is no need to copy this to a longitude-latitude version of the same file.
TODO: check that bgmlevels should only be an index, check that time_steps must be regular ?( or just monotonic incresing?)
the filename of the output (use ncdf4 to inspect, modify it)
tfile <- file.path(tempdir(), "my_hydrofile.nc")
(ncfile <- create_transport(tfile, bgmfilepath = bgmfiles::bgmfiles("antarctica_99")))
## use ncdf4::nc_open to inspect the file
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.