ctd_bplot: Plot contours of bottom water variable by station and time

View source: R/ctd_bplot.R

ctd_bplotR Documentation

Plot contours of bottom water variable by station and time

Description

Plot two-dimensional CTD contours for bottom water variable by station and time

Usage

ctd_bplot(
  dat_in,
  var_plo,
  date_col = "Date",
  num_levs = 8,
  expand = 200,
  txt_scl = 1,
  xlab = "Date",
  ylab = "Channel distance (km)",
  cols = c("tomato", "lightblue", "lightgreen", "green"),
  ncol = 100
)

Arguments

dat_in

ctd data along the tidal axis, as a data.frame

var_plo

chr string of variable to plot from dat_in

date_col

chr string of name of date column

num_levs

numeric for number of contour levels

expand

numeric for expanding sample size of CTD points, see get_depths

txt_scl

numeric for scaling all text labels

xlab

chr string for x-axis label

ylab

chr string for y-axis label

cols

chr string of colors for the plot

ncol

numeric indicating degree of smoothing for the color palette

Details

Raw data from the CTD are vertical profiles at unique stations for more than one date. The data are linearly interpolated between dates and stations to create a two-dimensional plotting surface. The dat_in data.frame must have at a minimum six columns for date (Date), longitude (Long), latitude (Lat), station name (Station), depth (Depth, non-negative), and the variable to plot.

Sample dates are shown as triangles on the top and station locations are shown on the right.

Value

The contour plot

Examples

# default plot
ctd_bplot(ctd, var_plo = 'DO')

fawda123/CTDplot documentation built on June 8, 2024, 1:07 p.m.