plotScan {oce} | R Documentation

## Plot CTD data in a Low-Level Fashion

### Description

Plot CTD data as time-series against scan number, to help with trimming extraneous data from a CTD cast.

### Usage

    plotScan(x, which = 1, xtype = "scan", type = "l",
      mgp = getOption("oceMgp"), mar = c(mgp[1] + 1.5, mgp[1] + 1.5, mgp[1],
      mgp[1]), ...)

### Arguments

`x` | A `ctd` object, i.e. one inheriting from `ctd-class`.
`which` | Numerical vector numerical codes specifying the panels to draw: 1 for pressure vs scan, 2 for `diff(pressure)` vs scan, 3 for temperature vs scan, and 4 for salinity vs scan.
`xtype` | Character string indicating variable for the x axis. May be `"scan"` (the default) or `"time"`. In the former case, a `scan` variable will be created using `seq_along`, if necessary. In the latter case, an error results if the `data` slot of `x` lacks a variable called `time`.
`type` | Character indicating the line type, as for `plot.default`. The default is `"l"`, meaning to connect data with line segments. Another good choice is `"o"`, to add points at the data.
`mgp` | Three-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` | Four-element vector be used with `par("mar")`. If set to `NULL`, then `par("mar")` is used. A good choice for a TS diagram with a palette to the right is `mar=par("mar")+c(0, 0, 0, 1))`.
`...` | Optional arguments passed to plotting functions.

### Author(s)

Dan Kelley

### See Also

Other functions that plot `oce` data: `plot,adp-method`, `plot,adv-method`, `plot,amsr-method`, `plot,argo-method`, `plot,bremen-method`, `plot,cm-method`, `plot,coastline-method`, `plot,ctd-method`, `plot,gps-method`, `plot,ladp-method`, `plot,lisst-method`, `plot,lobo-method`, `plot,met-method`, `plot,odf-method`, `plot,rsk-method`, `plot,satellite-method`, `plot,sealevel-method`, `plot,section-method`, `plot,tidem-method`, `plot,topo-method`, `plot,windrose-method`, `plotProfile`, `plotTS`, `tidem-class`

Other things related to `ctd` data: `[[,ctd-method`, `[[<-,ctd-method`, `as.ctd`, `cnvName2oceName`, `ctd-class`, `ctdDecimate`, `ctdFindProfiles`, `ctdRaw`, `ctdTrim`, `ctd`, `handleFlags,ctd-method`, `oceNames2whpNames`, `oceUnits2whpUnits`, `plot,ctd-method`, `plotProfile`, `plotTS`, `read.ctd.itp`, `read.ctd.odf`, `read.ctd.sbe`, `read.ctd.woce.other`, `read.ctd.woce`, `read.ctd`, `subset,ctd-method`, `summary,ctd-method`, `woceNames2oceNames`, `woceUnit2oceUnit`, `write.ctd`

### Examples

    library(oce)
    data(ctdRaw)
    plotScan(ctdRaw)
    abline(v=c(130, 350), col='red') # useful for ctdTrim()

[Package oce version 0.9-22 Index]