- section
A section object containing the section to be smoothed.
For method="spline", the pressure levels must match for each station in
the section.
- method
A string or a function that specifies the method to use; see “Details”.
- x
Optional numerical vector, of the same length as the number of stations in section,
which will be used in gridding in the lateral direction. If not provided, this
defaults to geodDist(section).
- xg, xgl
ignored in the method="spline" case, but passed to
interpBarnes() if method="barnes", to kriging
functions if method="kriging", or to method itself, if it
is a function.
If xg is supplied, it defines the x component of the grid, which by
default is the terms of station distances, x, along the track of the section. (Note
that the grid xg is trimmed to the range of the data x, because otherwise
it would be impossible to interpolate between stations to infer water depth,
longitude, and latitude, which are all stored within the stations in the
returned section object.)
Alternatively, if xgl is supplied, the x grid is established using seq(),
to span the data with xgl elements. If neither of these is supplied, the output
x grid will equal the input x grid.
- yg, ygl
similar to xg and xgl, but for pressure. (Note that
trimming to the input y is not done, as it is for xg and x.)
If yg is not given, it is determined from the deepest station in the section.
If ygl was not given, then a grid is constructed to span the pressures
of that deepest station with ygl elements. On the other hand,
if ygl was not given, then the y grid will constructed from the
pressure levels in the deepest station.
- xr, yr
influence ranges in x (along-section distance) and y (pressure),
passed to interpBarnes() if method="barnes" or to
method, if the latter is a function. If missing, xr defaults to
1.5X the median inter-station distance and yr defaults to 0.2X
the pressure range. Since these defaults have changed over the evolution
of sectionSmooth, analysts ought to supply xr and yr
in the function call, tailoring them to particular applications, and
making the code more resistant to changes in sectionSmooth.
- df
Degree-of-freedom parameter, passed to smooth.spline()
if method="spline", and ignored otherwise. If df is not provided,
it defaults to 1/5-th of the number of stations containing non-NA
data at the particular pressure level being processed, as sectionSmooth
works its way through the water column.
- gamma, iterations, trim, pregrid
Values passed to
interpBarnes(), if method="barnes", and
ignored otherwise. gamma is the factor by which
xr and yr are reduced on each of succeeding iterations.
iterations is the number of iterations to do.
trim controls whether the gridded data are set to
NA in regions with sparse data
coverage. pregrid controls whether data are to be
pre-gridded with binMean2D() before being passed to
interpBarnes().
- debug
A flag that turns on debugging. Set to 1 to get a moderate amount
of debugging information, or to 2 to get more.
- ...
Optional extra arguments, passed to either
smooth.spline(), if method="spline", and ignored otherwise.