The plot initially has descending depth on y-axis and ascending variable (e.g., Temperature) on x-axis with each line representing a unique CTD cast across each depth recorded. If the plot is interactive, then on hover the CTD cast (uniquely identified by cast_count) is highlighted in red and others dimmed in gray.

plot_depth(df, variable = "Temperature", interactive = TRUE)

Arguments

df

data frame with columns: cast_count, depth_m, v

variable

variable (character), should be one of plot_title from get_variables(); default: "Temperature"

interactive

whether to render interactive plot; default: TRUE

Value

interactive plot of type plotly::ggplotly() or static plot of type ggplot2::ggplot().

Examples

# plot depth with the station data
plot_depth(df = bottle_temp_depth, variable = "Temperature")