Learn R Programming

oce (version 0.2-1)

makeSection: Bind CTD profiles together into a cross section

Description

Combine a series of CTD profiles together to create a section.

Usage

makeSection(item, ...)
section + station

Arguments

item
either (1) a ctd object, in which case the rest of the arguments are other ctd objects, (2) a list of ctd objects, (3) a list of names of ctd objects, or (4) a list of names of files containi
...
one or more ctd objects, either given as separate arguments, or a list of such objects.
section
a section to which a station is to be added.
station
a station to be added to a section.

Value

Details

The stations are stored in order of the station identification number (stored as metadata$station in the ctd object), if possible. The ctd stations must share identical pressure values; use sectionGrid to do that.

See Also

read.ctd reads CTD data. section is a sample data set.

Examples

Run this code
library(oce)
data(ctd)
ctd.warmed <- ctd
ctd.warmed$data$temperature <- ctd.warmed$data$temperature + 0.5
ctd.warmed$metadata$latitude <- ctd.warmed$metadata$latitude + 0.1
section <- makeSection(ctd, ctd.warmed)
summary(section)

s2 <- makeSection(ctd)
s2 <- s2 + ctd.warmed
plot(s2)
plot(sectionSmooth(sectionGrid(makeSection(dir("*.csv")))))

Run the code above in your browser using DataLab