Prepare 'oce' objects as data frames for 'ggplot2'

# S3 method for ctd
fortify(model, ..., which = c("combined", "data", "metadata"))

# S3 method for section
fortify(model, ..., which = c("combined", "data", "metadata"))

# S3 method for adp
fortify(model, ..., which = c("velocity", "bottom_track", "metadata"))

Arguments

model

An 'oce' object

...

Additional columns/values to initialize. Tidy evaluation is supported.

which

Most objects can be summarised as data frames at several levels of granularity. The default is the most useful for plotting.

Value

A tibble::tibble()

Examples

library(ggplot2) data(ctd, package = "oce") fortify(ctd)
#> Loading required package: oce
#> Loading required package: gsw
#> Loading required package: testthat
#> Loading required package: sf
#> Linking to GEOS 3.8.1, GDAL 3.1.4, PROJ 6.3.1
#> # A tibble: 181 x 31 #> pressureType deploymentType waterDepth model type hexfilename serialNumber #> <chr> <chr> <lgl> <chr> <chr> <chr> <chr> #> 1 sea unknown NA 25 SBE "c:\\seasoft… "" #> 2 sea unknown NA 25 SBE "c:\\seasoft… "" #> 3 sea unknown NA 25 SBE "c:\\seasoft… "" #> 4 sea unknown NA 25 SBE "c:\\seasoft… "" #> 5 sea unknown NA 25 SBE "c:\\seasoft… "" #> 6 sea unknown NA 25 SBE "c:\\seasoft… "" #> 7 sea unknown NA 25 SBE "c:\\seasoft… "" #> 8 sea unknown NA 25 SBE "c:\\seasoft… "" #> 9 sea unknown NA 25 SBE "c:\\seasoft… "" #> 10 sea unknown NA 25 SBE "c:\\seasoft… "" #> # … with 171 more rows, and 24 more variables: serialNumberTemperature <chr>, #> # serialNumberConductivity <chr>, systemUploadTime <dttm>, ship <chr>, #> # scientist <chr>, institute <chr>, address <chr>, cruise <chr>, #> # station <chr>, date <dttm>, startTime <dttm>, recoveryTime <lgl>, #> # latitude <dbl>, longitude <dbl>, sampleInterval <dbl>, #> # sampleIntervalUnits <chr>, filename <chr>, scan <int>, timeS <dbl>, #> # pressure <dbl>, depth <dbl>, temperature <dbl>, salinity <dbl>, flag <dbl>