Skip to contents

These functions read in target variables from NEMO-MEDUSA model outputs and return weighted averages according to a summary scheme.

Usage

get_grid_T_slabR(
  path,
  file,
  scheme,
  start = c(1, 1, 1, 1),
  count = c(-1, -1, -1, -1),
  ice_scheme,
  ...
)

get_ptrc_T_slabR(
  path,
  file,
  scheme,
  start = c(1, 1, 1, 1),
  count = c(-1, -1, -1, -1),
  ...
)

get_grid_W_slabR(
  path,
  file,
  scheme_w,
  start_w = c(1, 1, 1, 1),
  count_w = c(-1, -1, -1, -1),
  ...
)

get_grid_V_slabR(
  path,
  file,
  scheme,
  start = c(1, 1, 1, 1),
  count = c(-1, -1, -1, -1),
  ...
)

get_grid_U_slabR(
  path,
  file,
  scheme,
  start = c(1, 1, 1, 1),
  count = c(-1, -1, -1, -1),
  ...
)

get_icemod_slabR(
  path,
  file,
  scheme,
  start = c(1, 1, 1, 1),
  count = c(-1, -1, -1, -1),
  ice_scheme,
  ...
)

Arguments

path

the path to the NEMO-MEDUSA model outputs.

file

the name of a netcdf file containing the title variables.

scheme

a summary scheme as expected by array_w_mean().

start

an optional vector of indices to start subsetting at. See ncdf4 documentation.

count

an optional vector of steps to subset along. See ncdf4 documentation.

ice_scheme

a separate summary scheme for the 2D ice variables.

...

soaks up unused function arguments passed by the wrapper functions handling file architecture.

scheme_w

as above but for grid_W files.

start_w

as above but for grid_W files.

count_w

as above but for grid_W files.

Value

A matrix with a column of group averages per title variable for a single day.

Details

Each variable of interest in a netcdf file is imported, only reading within an x/y window specified with start and count. The values are then passed to array_w_mean() to summarise according to a scheme.

Each model output file type contains a different set of variables, extracted by the relevant function variant:

File type        Variables
grid_T_Salinity, temperature, sea ice concentration.
grid_U_Zonal currents.
grid_V_Meridional currents.
grid_W_Vertical velocity, vertical eddy diffusivitiy.
icemod_Ice presence, ice thickness, snow thickness.
ptrc_T_DIN, phytoplankton nitrogen content.

Some function variants have different arguments:

grid_T_ and icemod_ functions accept an ice_scheme. Cryosphere data is contained in matrices not arrays.

grid_W_ expects it's own scheme_w as depth levels are different between these and other files. it also expects it's own start_w and count_w.

See also

Other NEMO-MEDUSA variable extractors: NEMO_MEDUSA(), extractors_1D, get_spatial()