library(oce)
profile <- read.ctd("/usr/local/lib/R/library/oce/demo/ctdprofile.cnv")
attach(profile)
plot.TS(profile)
# North Atlantic thermocline water, mixing to Antarctic Intermediate Water
# (after Defant's analysis)
N <- 10
Srange <- c(34.15, 35.94)
Trange <- c(3.3,18)
SS <- Srange[1] + (Srange[2] - Srange[1]) *(1:N)/(N-1) + 0.01*rnorm(N)
TT <- Trange[1] + (Trange[2] - Trange[1]) *(1:N)/(N-1) + 0.01*rnorm(N)
plot.TS(as.CTD(S=SS, T=TT, p=0),type='b',pch=19)Run the code above in your browser using DataLab