Learn R Programming

oce (version 0.2-1)

plot.cm: Plot cm (current meter) data

Description

Plot cm (current meter) data

Usage

## S3 method for class 'cm':
plot(x,
     which=c(1, 2, 7, 9),
     type="l",
     adorn=NULL,
     drawTimeRange=getOption("oceDrawTimeRange"),
     drawZeroLine=FALSE,
     mgp=getOption("oceMgp"),
     mar=c(mgp[1]+1.5,mgp[1]+1.5,1.5,1.5),
     small=2000,
     main="",
     debug=getOption("oceDebug"),
     ...)

Arguments

x
an cm object, e.g. as read by read.cm.
which
list of desired plot types. These are graphed in panels running down from the top of the page. See Details for the meanings of various values of which.
type
type of plot, as for plot.
adorn
optional list of expressions to be performed immediately after drawing the panels. (See plot.adp for an example.)
drawTimeRange
boolean that applies to panels with time as the horizontal axis, indicating whether to draw the time range in the top-left margin of the plot.
drawZeroLine
boolean that indicates whether to draw zero lines on velocities.
mgp
3-element numerical vector to use for par(mgp), and also for par(mar), computed from this. The default is tighter than the R default, in order to use more space for the data and less for the axes.
mar
value to be used with par("mar").
small
an integer indicating the size of data set to be considered "small", to be plotted with points or lines using the standard plot function. Data sets with more than small po
main
main title for plot, used just on the top panel, if there are several panels.
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 arguments passed to plotting functions.

Details

Creates a multi-panel summary plot of data measured by a current meter. The panels are controlled by the which argument, as follows.
  • which=1orwhich="u"for a time-series graph of eastward velocity,u, as a function of time.
  • which=2orwhich="v"for a time-series graph of northward velocity,u, as a function of time.
  • which=3or"progressive vector"for progressive-vector plot
  • which=4or"uv"for a plot ofvversusu. (Dots are used for small datasets, and smoothScatter for large ones.)
  • which=5or"uv+ellipse"as the"uv"case, but with an added indication of the tidal ellipse, calculated from the eigen vectors of the covariance matrix.
  • which=6or"uv+ellipse+arrow"as the"uv+ellipse"case, but with an added arrow indicating the mean current.
  • which=7or"depth"for depth
  • which=8or"salinity"for salinity
  • which=9or"temperature"for temperature
  • which=10or"heading"for heading
  • which=11or"TS"for a TS diagram

See Also

See read.cm for notes on functions relating to "cm" objects.

Examples

Run this code
library(oce)
cm <- read.oce("cm_interocean_0811786.s4a.tab")
summary(cm)
plot(cm)

Run the code above in your browser using DataLab