| estThermo | R Documentation |
Estimate average thermocline depth across multiple sites and dates.
estThermo(data, site, date, depth, temp, combine = "all", type = "midpoint")
data |
data frame of water column temperature profiles |
site |
character giving the name of the site column |
date |
character giving the name of the date column |
depth |
character giving the name of the depth column |
temp |
character giving the name of the temp column |
combine |
character indicating whether to average across sites ("sites"), dates ("dates"), sites and dates ("all"), or not at all ("none"), default = "all". When combine = "none", each site/date combination is returned individually with no averaging. |
type |
character indicating whether to estimate a single thermocline midpoint depth ("midpoint") or the upper and lower depths bounding the metalimnion ("top_bottom"), default = "midpoint". "midpoint" wraps |
a data frame. When type = "midpoint": thermocline midpoint depths, standard deviations, and n (combine = "sites", "dates", or "all"), or one row per site/date combination giving that profile's midpoint depth (combine = "none"). When type = "top_bottom": upper and lower metalimnion boundary depths, standard deviations, and n (combine = "sites", "dates", or "all"), or one row per site/date combination giving that profile's upper and lower boundary depths (combine = "none").
Tristan Blechinger, Department of Zoology & Physiology, University of Wyoming
# load test profile data
data <- read.csv(system.file("extdata", "example_profile_data.csv", package = 'rLakeHabitat'))
data$date <- base::as.Date(data$date)
#run function
estThermo(data = data, site = "site", date = "date",
depth = "depth", temp = "temp", combine = "all")
#or, to get each site/date profile's thermocline depth individually:
estThermo(data = data, site = "site", date = "date",
depth = "depth", temp = "temp", combine = "none")
#or, to estimate upper and lower metalimnion boundaries instead of a single midpoint:
estThermo(data = data, site = "site", date = "date",
depth = "depth", temp = "temp", combine = "none", type = "top_bottom")
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.