echogram: Echogram visualisation

View source: R/echogram.R

echogramR Documentation

Echogram visualisation

Description

This function allows to produce echogram visualisations from imported hac data. The user can define the visualisation Sv threshold and select between two built-in color schemes or define a custom scheme.

Usage

echogram(echogram, Svthr = -70, Svmax = 0, col.sep = NULL, col.nb = NULL,
         scheme = NULL, depth.grid = NULL, x.grid = NULL, 
         x.ref = c("pings", "nmi", "seconds"), seabed = FALSE, 
         depth.max = NULL, ping.ini = NULL, ping.max = NULL, colbar=TRUE, 
         main = NULL, tformat = "%H:%M", restore.par = TRUE, ...)

Arguments

echogram

an object of class “echogram” as returned by read.echogram.

Svthr

Sv visualisation threshold, in decibels (dB).

Svmax

maximum Sv visualisation value, in dB.

col.sep

separation between colors. Defaults to 1 dB.

col.nb

number of colors.

scheme

color scheme for echogram, “parula” (the default), “EK500”, or “echov”. It can also be a vector of valid color names, or a function generating color names.

depth.grid

spacing between depth labels (in m).

x.grid

spacing between labels in the horizontal dimension according to x.ref.

x.ref

horizontal reference in echogram: “pings” (the default), “nmi” or “seconds”.

seabed

logical. When TRUE and data on detected bottom is present, a line is added to the echogram.

depth.max

maximum depth to visualise.

ping.ini

initial ping to visualise.

ping.max

last ping to visualise.

colbar

logical. If TRUE a color bar is added to the echogram.

main

the acoustic frequency, by default.

tformat

time format for annotating when horizontal dimension when x.ref = 'seconds'.

restore.par

logical. If TRUE (the default), the graphical device is restored to its original state.

...

other options to image.

Details

Besides the two built-in color schemes, the user can define its own by specifying a vector of valid color names (see examples). This function uses imageScale function from sinkr package by Marc Taylor.

Author(s)

Héctor Villalobos

See Also

palette.echogram.

Examples

# import hac file
hacfile <- system.file("extdata", "D20150510-T202500.hac", package = "echogram")
echo2.038 <- read.echogram(hacfile)

# echogram by default 
echogram(echo2.038)

# using alternative color schemes
echogram(echo2.038, Svthr = -70, col.sep = 1.5, scheme = "EK500")
echogram(echo2.038, Svthr = -70, col.sep = 3, scheme = c("white", "blue", "grey", "black"))

hvillalo/echogram documentation built on Oct. 2, 2023, 7:28 a.m.