install.packages('pak')
Note that whenever the waterNETN package is updated, you
can rerun this code to install the latest version.
library(pak)
pkg_install("doi-nps/waterNETN")
library(waterNETN)
Note that R is not able to connect to files on Sharepoint or MS Teams
(b/c Teams also stores all files on Sharepoint). That means you need to
store data package files on your local machine or on a server (e.g. NETN
Z drive). The default option for importing data will add the data
package views (i.e., flatfiles) to an environment called VIEWS_WQ to
your Environment work space (i.e. Environment tab in top right panel).
If you would rather import each individual view into your R session,
specify with the new_env argument (e.g.,
importData(new_env = F)).
Option 1. Import data via .csv files. The file path should be where csvs are on your machine or server.
importData(type = 'csv',
filepath = "./data/records-2313941") # update filepath to your computer
Option 2. Import data via zip file of csvs. The filepath should be the location and name of the zip file.
importData(type = 'zip',
filepath = "./data/records-2313941.zip")
Option 3. Import data via data package database file on your computer
importData(type = 'dbfile',
filepath = "./data/NETN_h3Ov4_DataPackage_202331115.accdb")
Option 4. Import data via data package database DSN (Data Source Name) on your computer. Note that this is the default setting. As long as you have a named DSN called “NETNWQ_DP” that links to the data package database, and that database links to the latest NETN WQ backend database, the code below will run. See Setting up DSN tab for how to set up DSN.
importData() # easiest but must have DSN set up
importData(type = 'DSN', odbc = "NETNWQ_DP") # equivalent to line above
You can export all of the csvs to a zip file with the day’s date stamped on the file name. This allows you to import the tables from the database, then export the csvs as one zip file.
importData() # easiest bust must have DSN set up
exportData(filepath = "./data", zip = TRUE)
The functions in the waterNETN package are designed to
work with the views, and are the best way to interact with the data to
query by park, site, site type, year, parameter, etc. However, if you
want to view the raw data, and you imported the data into the VIEWS_WQ
environment, you can access them with the code below:
# See list of the views
names(VIEWS_WQ)
# View one of the views
View(VIEWS_WQ$Chemistry_Data)
# Assign a view to a data frame named chem in R. Interact with chem the way you would work with any normal data frame in R.
chem <- VIEWS_WQ$Chemistry_Data
If you want to use the print_head() function that shows
output in the markdown, run the code below. This makes the results print
cleaner in the markdown report. For your purposes, you can just run:
head(dataframe).
print_head <- function(df){
knitr::kable(df[1:6,]) |> #, table.attr = "style='width:60%;'") |>
kableExtra::kable_classic(full_width = F, font_size = 12,
bootstrap_options = c("condensed"))
}
The functions in waterNETN have help documentation like
any R package. To view the help, you can go to the Packages tab and
click on waterNETN (see below). That will show you all the functions in
the package. Clicking on individual functions will take you to the help
documentation for that function.
You can also see the help of a function by running, for example:
?importData
If waterNETN isn’t loaded yet, you’d run:
?waterNETN::importData
Each function’s help includes a Description, Usage (i.e. function arguments and their defaults), Argument options/definitions, and several examples showing how the function can be used.
This is where you come in! If you notice typos or can think of better descriptions, examples, error messages, etc., please send them my way! After we’re more comfortable with R packages and get versed on GitHub, you’ll be able to make those changes directly in the package. For now, you can just send me your suggestions and I’ll make the changes.
Finally, if you ever want to peak under the hood at the function, you can view it several ways.View code in the GitHub doi-nps/waterNETN repo. The functions are in the R folder.
Before FileMaker Go files are ingested into the MS Access database,
use the prepFMtoAccess() function to scrub placeholder
values from the exported .csv files. The function converts placeholder
values that FileMaker uses to prevent null values to NAs when “No
measurement” is selected for Datum Name and/or Discharge Method in the
FileMaker Go application. Additionally, it converts certain placeholder
values to NAs when “No water sample taken” is recorded in the
application. The table below shows the FileMaker Go export placeholders
that are converted to NAs for both Stream and Lake applications.
| FileMaker app | FileMaker export column name | FileMaker export value | Ingestion script replacement value |
|---|---|---|---|
| Lake | Stage_GageReading | 0 | NA |
| Lake | Stage_Time | 00:00:00 | NA |
| Lake, Stream | WaterSample_QC_IBWExp | 1/1/0001 | NA |
| Lake, Stream | WaterSample_QC_Time | 00:00:00 | NA |
| Lake, Stream | WaterSample_Time | 00:00:00 | NA |
| Stream | Flow_AvgVel | 0 | NA |
| Stream | Flow_Discharge_calc | 0 | NA |
| Stream | Flow_Discharge_cfs | 0 | NA |
| Stream | Flow_TotalArea | 0 | NA |
| Stream | Flow_TotalWidth | 0 | NA |
| Stream | FlowTrackerTemp | 0 | NA |
| Stream | tbl_Stage::Stage_Reading_1 | 0 | NA |
| Stream | tbl_Stage::Stage_Reading_2 | 0 | NA |
| Stream | tbl_Stage::Stage_Time_1 | 00:00:00 | NA |
| Stream | tbl_Stage::Stage_Time_2 | 00:00:00 | NA |
The prepFMtoAccess() function requires users to specify
the path and file name, and currently works with xlsx files for import
and csv for export. The function will determine whether the data is from
a lake or stream based on column names. The function then exports a csv
in the same filepath and with the same excel_name with
‘cleaned’ and the date added to the filename, and that is ready
to be imported into MS Access. Note that function can only work with
lake or stream data, not both in the same function call. Examples are
below. Note that additional testing of the data and import in MS Access
is necessary to ensure dates and GUIDs are importing properly. Depending
on how the MS Access import works, the cleaned csv may need to be opened
in Excel and saved as an xlsx. Better yet, the export from FileMaker is
as a csv or txt file instead of xlsx.
Clean lake data and return cleaned data in global environment.
prepFMtoAccess(filepath = "../data", excel_name = "ACAD_WQ_Lakes_2025-06.xlsx", keep_file = T)
Clean stream data.
prepFMtoAccess(filepath = "../data", excel_name = "ACAD_WQ_Stream_2025-06.xlsx")
Query site-level data. This function combines columns in common between the Sites_Stream and Sites_Lake views. This is a good building block for other functions, but may be less helpful on its own. Though, one helpful use of this function is to get the site codes for a given park or site.
Get site info for ACAD streams
ACAD_streams <- getSites(park = 'ACAD', site_type = 'stream')
print_head(ACAD_streams)# top 6 rows
| GroupCode | GroupName | UnitCode | UnitName | SubUnitCode | SubUnitName | SiteCode | SiteName | SiteType | SiteLatitude | SiteLongitude | Datum | ContribWshedArea_km2 | SiteDescription | Notes | LegislativeClass | IsPointCUI | site_type |
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| NETN | Northeast Temperate Network | ACAD | Acadia National Park | NA | NA | ACABIN | Aunt Betty Pond Inlet | Stream | 44.36502 | -68.27243 | NAD83 | 2.48 | The inlet flows north from Gilmore Meadow into Aunt Betty Pond. | Beavers often present both US & DS of carriage road. | AA | FALSE | stream |
| NETN | Northeast Temperate Network | ACAD | Acadia National Park | NA | NA | ACBRKB | Breakneck Brook | Stream | 44.41093 | -68.25175 | NAD83 | 3.72 | The stream flows north from the Breakneck Ponds and into the ocean (Hulls Cove). | Exact sampling point can vary depending on streamflow/water level. Hits baseflow in dry years. | AA | FALSE | stream |
| NETN | Northeast Temperate Network | ACAD | Acadia National Park | NA | NA | ACBRWN | Browns Brook | Stream | 44.33908 | -68.30123 | NAD83 | 1.18 | The stream flows northwest from Parkman Mountain into the ocean (Somes Sound). Measure east (US) of culvert under Sargent Drive. | Very close to municipal sand/salt storage facility. | AA | FALSE | stream |
| NETN | Northeast Temperate Network | ACAD | Acadia National Park | NA | NA | ACCADS | Cadillac Stream | Stream | 44.34480 | -68.21700 | NAD83 | 0.62 | On right bank approximately 500 feet upstream of the crossing of Canon Brook Trail (500 ft upstream from confluence with Otter Creek and 0.5 miles southeast of Cadillac summit) | High-elevation stream flows south on the east face of Cadillac mountain into Canon Brook- Otter Creek. Former site of USGS stream gage 01022835 (1999- 2006). | AA | FALSE | stream |
| NETN | Northeast Temperate Network | ACAD | Acadia National Park | NA | NA | ACDKLI | Duck Pond Brook | Stream | 44.33123 | -68.37826 | NAD83 | 0.48 | The stream flows north from Duck Pond into Long Pond (MDI). | Can be near or at baseflow in dry years and difficult to measure streamflow. | AA | FALSE | stream |
| NETN | Northeast Temperate Network | ACAD | Acadia National Park | NA | NA | ACDUCK | Duck Brook | Stream | 44.37760 | -68.24509 | NAD83 | 9.62 | Sample site is located north of Rte. 233 crossing, approx. 200 ft. DS of culvert. | Duck Brook flows north from Eagle Lake into the ocean (Hulls Cove/Frenchman Bay). Established in 2009, replaces ACEGLO. | AA | FALSE | stream |
Get site info for all sites in MABI
mabi <- getSites(park = "MABI")
print_head(mabi)# top 6 rows
| GroupCode | GroupName | UnitCode | UnitName | SubUnitCode | SubUnitName | SiteCode | SiteName | SiteType | SiteLatitude | SiteLongitude | Datum | ContribWshedArea_km2 | SiteDescription | Notes | LegislativeClass | IsPointCUI | site_type | |
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| 1 | NETN | Northeast Temperate Network | MABI | Marsh-Billings-Rockefeller National Historical Park | NA | NA | MABISA | Pogue Brook | Stream | 43.63493 | -72.52937 | NAD83 | 0.99 | Only stream within the park, the outlet of The Pogue. One stream-sampling site was selected to represent Pogue Brook. This site was chosen because it is the most downstream location within park boundaries. | None | A(1) | FALSE | stream |
| 2 | NETN | Northeast Temperate Network | MABI | Marsh-Billings-Rockefeller National Historical Park | NA | NA | MABIPA | The Pogue | Lake | 43.63336 | -72.54263 | NAD83 | 0.57 | The Pogue is a 14-acre pond at the headwaters of the Pogue Brook. Naturally a spring-fed boggy area, it was created in the 1880s with an earthen dam. Swimming, fishing, or wading is prohibited. | None | A(1) | FALSE | lake |
| NA | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA |
| NA.1 | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA |
| NA.2 | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA |
| NA.3 | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA |
List site codes and their full site name for SARA
sara_sites <- getSites(park = "SARA") |> select(SiteCode, SiteName)
print_head(sara_sites)# top 6 rows
| SiteCode | SiteName | |
|---|---|---|
| 1 | SARASA | Kroma Kill |
| 2 | SARASC | Upper Mill Creek |
| 3 | SARASD | Mill Creek Confluence |
| NA | NA | NA |
| NA.1 | NA | NA |
| NA.2 | NA | NA |
Get all fields of site info for Primrose Brook in MORR
prim <- getSites(site = "MORRSB", output = "verbose")
print_head(prim)# top 6 rows
| GroupCode | GroupName | UnitCode | UnitName | SubUnitCode | SubUnitName | SiteCode | SiteName | SiteType | SiteLatitude | SiteLongitude | Datum | ContribWshedArea_km2 | SiteDescription | Notes | LegislativeClass | IsPointCUI | site_type | |
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| 1 | NETN | Northeast Temperate Network | MORR | Morristown National Historical Park | NA | NA | MORRSB | Primrose Brook Confluence | Stream | 40.76506 | -74.52978 | NAD83 | 2.79 | The monitoring site is located downstream of the USGS staff gage (01378780) installed just below the confluence of East and West Primrose Brooks. | Primrose Brook, a tributary of the Passaic River, drains an area almost entirely contained within the Jockey Hollow Unit of Morristown NHP. | A | FALSE | stream |
| NA | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA |
| NA.1 | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA |
| NA.2 | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA |
| NA.3 | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA |
| NA.4 | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA |
Get site info for ACAD lakes
ACAD_lakes <- getSitesLake(park = "ACAD")
print_head(ACAD_lakes)# top 6 rows
| SiteCode | SiteName | UnitCode | SubUnitCode | HUC12 | ContribWshedArea_km2 | Inlet | Outlet | MaxDepth_m | TrophicType | LegislativeClass | FishMgtType | SiteDescription | Notes |
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| ACANTB | Aunt Bettys Pond | ACAD | NA | 10500021502 | 2.77 | unnamed | RICHARDSON BRK | 2.1 | EUTROPHIC | GPA | COLDWATER | Shallow, marshy pond with an area of 31.5 acres. Inlet: Aunt Betty Inlet. Outlet: Richardson Brook. | Pond is full of emergent vegetation by mid-summer. Deep hole is in NE corner, near outlet. Surrounded by ANP. Last surveyed by IFW in 1982. Closed to ice fishing. |
| ACBOWL | The Bowl | ACAD | NA | 10500021501 | 0.21 | NA | OTTER CREEK | 9.0 | MESOTROPHIC | GPA | NONE | High elevation, mesotrophic pond located between Cahamplaine Mtn. and The Beehive. | Located off the Beehive Trail. Fish survey conducted in 1995 BY J.R. Burgess. Not monitored by NETN- sampled annually for acid depositon effects by ACAD staff. Once served as water supply for Satterlee estate. |
| ACBRBK | Bear Brook Pond | ACAD | NA | 10500021501 | NA | BEAR BROOK | BEAR BROOK | 3.9 | MESOTROPHIC | GPA | NONE | Mesotrophic, unstratified pond with an area of 7.5 acres. Its inlet and outlet is Bear Brook. | Located on Park Loop Road near Jackson Lab. Site of ANP purple loosestrife monitoring/control plots. Active beaver in area. Fish survey in 1995 by J.R. Burgess. Also known as Beaver Dam Pond. |
| ACBUBL | Bubble Pond | ACAD | NA | 10500021501 | 1.77 | unnamed | BUBBLE BROOK | 11.9 | MESOTROPHIC | GPA | COLDWATER | Oligotrophic, stratified lake with an area of 33 acres. Part of the public water supply. Inlet: unnamed stream on southern end. Outlet: Bubble Brook. | Surrounded by ANP. Connects with Bar Harbor water supply. Last surveyed by IFW in 1942. Closed to ice fishing. |
| ACEAGL | Eagle Lake | ACAD | NA | 10500021501 | 5.60 | BUBBLE BROOK | DUCK BROOK | 33.5 | OLIGOTROPHIC | GPA | COLDWATER | Oligotrophic, stratified lake with an area of 465.8 acres. Part of the public water supply. Inlet: Bubble Brook. Outlet: Duck Brook. | LLS spawning area built in outlet in 55. 10 hp outboard limit. Last surveyed by IFW in 1990. Surrounded by ANP. |
| ACECHO | Echo Lake | ACAD | NA | 10500021502 | 5.10 | LURVEY SPRG BRK | DENNING BROOK | 20.1 | OLIGOTROPHIC | GPA | COLDWATER | Oligotrophic, stratified lake with an area of 236.8 acres. Inlet: Lurvey Spring Brook. Outlet: Denning Brook. | Partial boundary w/ANP. Last surveyed by IFW in 1988. Outboard hp restrictions. Reclaimed in 1956. Guarded ANP swim beach on south end. |
Get all site info for the Pogue Pond
pogue <- getSitesLake(site = "MABIPA", output = 'verbose')
print_head(pogue)# top 6 rows
| GroupCode | GroupName | UnitCode | UnitName | SubUnitCode | SubUnitName | SiteCode | SiteName | SiteType | SiteLatitude | SiteLongitude | Datum | HUC12 | ContribWshedArea_km2 | Inlet | Outlet | MaxDepth_m | TrophicType | LegislativeClass | FishMgtType | SiteDescription | Notes | IsPointCUI | |
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| 1 | NETN | Northeast Temperate Network | MABI | Marsh-Billings-Rockefeller National Historical Park | NA | NA | MABIPA | The Pogue | Lake | 43.63336 | -72.54263 | NAD83 | 10801060206 | 0.57 | NA | Pogue Brk | 3.4 | MESOTROPHIC | A(1) | COLDWATER | The Pogue is a 14-acre pond at the headwaters of the Pogue Brook. Naturally a spring-fed boggy area, it was created in the 1880s with an earthen dam. Swimming, fishing, or wading is prohibited. | None | FALSE |
| NA | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA |
| NA.1 | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA |
| NA.2 | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA |
| NA.3 | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA |
| NA.4 | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA |
Get all site info for lakes in LNETN
lnetn <- c("MABI", "MIMA", "MORR", "ROVA", "SAGA", "SAIR", "SARA", "WEFA")
lnetn_lks <- getSitesLake(park = lnetn)
print_head(lnetn_lks)# top 6 rows
| SiteCode | SiteName | UnitCode | SubUnitCode | HUC12 | ContribWshedArea_km2 | Inlet | Outlet | MaxDepth_m | TrophicType | LegislativeClass | FishMgtType | SiteDescription | Notes | |
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| 1 | MABIPA | The Pogue | MABI | NA | 10801060206 | 0.57 | NA | Pogue Brk | 3.40 | MESOTROPHIC | A(1) | COLDWATER | The Pogue is a 14-acre pond at the headwaters of the Pogue Brook. Naturally a spring-fed boggy area, it was created in the 1880s with an earthen dam. Swimming, fishing, or wading is prohibited. | None |
| 2 | SAGAPA | Blow-Me-Down Pond | SAGA | NA | 10801060303 | 117.15 | Blow-Me-Down Br | Blow-Me-Down Br | 2.03 | MESOTROPHIC | A | WARMWATER | Blow-Me-Down Pond, the result of the impoundment of Blow-Me-Down Brook, has been a water quality site measured by the park since 1997 (Historic site 5). Concerns for the site include siltation of the area behind the dam. | Listed as impaired for fish consumption (Hg) in 2012) |
| 3 | WEFAPA | Weir Pond | WEFA | NA | 11000060202 | 0.36 | NA | unnamed stream | 2.09 | MESOTROPHIC | AA | WARMWATER | J. A. Weir authorized workers to construct an earthen dam in 1896 to form the 3.28 acre pond. The pond has been used for artistic inspiration, recreational fishing, as a hiking destination, and as a source of ice until the 1940s. | Dam extends >200’ along the NE perimeter & varies in width from 8- 10’. A roughly circular section of land in the NE section was likely left unexcavated to form an island on which Weir built a summerhouse (gone by 1930s). AKA Nod Hill Pond (CT DEEP map). |
| NA | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA |
| NA.1 | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA |
| NA.2 | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA |
Get site info for ACAD streams
ACAD_str <- getSitesStream(park = "ACAD")
print_head(ACAD_str)# top 6 rows
| SiteCode | UnitCode | SubUnitCode | USGS_StaNumb | ContribWshedArea_km2 | SiteDescription | Notes | LegislativeClass | FisheryType |
|---|---|---|---|---|---|---|---|---|
| ACABIN | ACAD | NA | 1022869 | 2.48 | The inlet flows north from Gilmore Meadow into Aunt Betty Pond. | Beavers often present both US & DS of carriage road. | AA | Warmwater |
| ACBRKB | ACAD | NA | 1022825 | 3.72 | The stream flows north from the Breakneck Ponds and into the ocean (Hulls Cove). | Exact sampling point can vary depending on streamflow/water level. Hits baseflow in dry years. | AA | Coldwater |
| ACBRWN | ACAD | NA | 1022866 | 1.18 | The stream flows northwest from Parkman Mountain into the ocean (Somes Sound). Measure east (US) of culvert under Sargent Drive. | Very close to municipal sand/salt storage facility. | AA | Coldwater |
| ACCADS | ACAD | NA | 1022835 | 0.62 | On right bank approximately 500 feet upstream of the crossing of Canon Brook Trail (500 ft upstream from confluence with Otter Creek and 0.5 miles southeast of Cadillac summit) | High-elevation stream flows south on the east face of Cadillac mountain into Canon Brook- Otter Creek. Former site of USGS stream gage 01022835 (1999- 2006). | AA | Coldwater |
| ACDKLI | ACAD | NA | 10228755 | 0.48 | The stream flows north from Duck Pond into Long Pond (MDI). | Can be near or at baseflow in dry years and difficult to measure streamflow. | AA | Coldwater |
| ACDUCK | ACAD | NA | 1022827 | 9.62 | Sample site is located north of Rte. 233 crossing, approx. 200 ft. DS of culvert. | Duck Brook flows north from Eagle Lake into the ocean (Hulls Cove/Frenchman Bay). Established in 2009, replaces ACEGLO. | AA | Coldwater |
Get all site info for the Pogue Stream
poguestr <- getSitesStream(site = "MABISA", output = 'verbose')
print_head(poguestr)# top 6 rows
| GroupCode | GroupName | UnitCode | UnitName | SubUnitCode | SubUnitName | SiteCode | SiteName | SiteType | SiteLatitude | SiteLongitude | Datum | USGS_StaNumb | ContribWshedArea_km2 | SiteDescription | Notes | LegislativeClass | FisheryType | IsPointCUI | |
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| 1 | NETN | Northeast Temperate Network | MABI | Marsh-Billings-Rockefeller National Historical Park | NA | NA | MABISA | Pogue Brook | Stream | 43.63493 | -72.52937 | NAD83 | NA | 0.99 | Only stream within the park, the outlet of The Pogue. One stream-sampling site was selected to represent Pogue Brook. This site was chosen because it is the most downstream location within park boundaries. | None | A(1) | Coldwater | FALSE |
| NA | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA |
| NA.1 | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA |
| NA.2 | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA |
| NA.3 | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA |
| NA.4 | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA |
Get all site info for streams in LNETN
lnetn <- c("MABI", "MIMA", "MORR", "ROVA", "SAGA", "SAIR", "SARA", "WEFA")
lnetn_str <- getSitesStream(park = lnetn)
print_head(lnetn_str)# top 6 rows
| SiteCode | UnitCode | SubUnitCode | USGS_StaNumb | ContribWshedArea_km2 | SiteDescription | Notes | LegislativeClass | FisheryType |
|---|---|---|---|---|---|---|---|---|
| MABISA | MABI | NA | NA | 0.99 | Only stream within the park, the outlet of The Pogue. One stream-sampling site was selected to represent Pogue Brook. This site was chosen because it is the most downstream location within park boundaries. | None | A(1) | Coldwater |
| MIMASA | MIMA | NA | NA | 406.56 | The Mill Brook site is located upstream of Lowell Road between a small retail complex and a private residence. | The monitoring site is located outside park boundaries because the brook is intermittent where it flows through the Wayside Unit and becomes a wetland where it flows through the North Bridge Unit. | A | Coldwater |
| MIMASB | MIMA | NA | 110057120 | 1.58 | The Elm Brook site is within park boundaries at State Route 2A, 4.3 miles upstream from the confluence with the Shawsheen River. The sampling site represents water quality conditions in Elm Brook within the Battle Road Unit. | None | A | Coldwater |
| MIMASC | MIMA | NA | NA | 860.72 | The Concord River site is at the Old North Bridge, 0.49 miles downstream from the confluence of the Sudbury and Assabet Rivers. The site is intended to represent water quality conditions in the Concord River within the North Bridge Unit. | In situ WQ measurements are taken at 7 points (near both banks and at each of 5 bridge pylons, measured at half depth) on the bridge. Cumulative watershed area: 212,688.73 acres (860.72 km2) | A | Warmwater |
| MORRSB | MORR | NA | 1378780 | 2.79 | The monitoring site is located downstream of the USGS staff gage (01378780) installed just below the confluence of East and West Primrose Brooks. | Primrose Brook, a tributary of the Passaic River, drains an area almost entirely contained within the Jockey Hollow Unit of Morristown NHP. | A | Coldwater |
| MORRSD | MORR | NA | 1378680 | 5.62 | The Indian Grove Brook monitoring site is located near where the brook first enters the park, just downstream of the Hardscrabble Road bridge. | A tributary of the Passaic River, the brook meanders in and out of the western boundary of the New Jersey Brigade Encampment Unit. Upstream of the monitoring site, the watershed is characterized by a low-density suburban, but largely forested, landscape. | A | Coldwater |
Query water data by park, site, site_type, year and month.
Get events for all sites in MABI from 2021-2023
mabi <- getEvents(park = "MABI", years = 2021:2023)
print_head(mabi)# top 6 rows
| UnitCode | UnitName | SiteCode | SiteName | SiteType | SiteLatitude | SiteLongitude | EventDate | EventCode | year | month | doy | Project |
|---|---|---|---|---|---|---|---|---|---|---|---|---|
| MABI | Marsh-Billings-Rockefeller National Historical Park | MABIPA | The Pogue | Lake | 43.63336 | -72.54263 | 2021-05-24 | 4178 | 2021 | 5 | 144 | NETN_LS |
| MABI | Marsh-Billings-Rockefeller National Historical Park | MABIPA | The Pogue | Lake | 43.63336 | -72.54263 | 2021-06-22 | 4192 | 2021 | 6 | 173 | NETN_LS |
| MABI | Marsh-Billings-Rockefeller National Historical Park | MABIPA | The Pogue | Lake | 43.63336 | -72.54263 | 2021-07-20 | 4239 | 2021 | 7 | 201 | NETN_LS |
| MABI | Marsh-Billings-Rockefeller National Historical Park | MABIPA | The Pogue | Lake | 43.63336 | -72.54263 | 2021-08-25 | 4281 | 2021 | 8 | 237 | NETN_LS |
| MABI | Marsh-Billings-Rockefeller National Historical Park | MABIPA | The Pogue | Lake | 43.63336 | -72.54263 | 2021-09-21 | 4315 | 2021 | 9 | 264 | NETN_LS |
| MABI | Marsh-Billings-Rockefeller National Historical Park | MABIPA | The Pogue | Lake | 43.63336 | -72.54263 | 2021-10-22 | 4349 | 2021 | 10 | 295 | NETN_LS |
Get events for SARA sites sampled in 2019 and 2023
sara <- getEvents(park = "SARA", years = c(2019, 2023))
print_head(sara) # top 6 rows
| UnitCode | UnitName | SiteCode | SiteName | SiteType | SiteLatitude | SiteLongitude | EventDate | EventCode | year | month | doy | Project |
|---|---|---|---|---|---|---|---|---|---|---|---|---|
| SARA | Saratoga National Historical Park | SARASA | Kroma Kill | Stream | 43.00583 | -73.6173 | 2019-05-16 | 3790 | 2019 | 5 | 136 | NETN_LS |
| SARA | Saratoga National Historical Park | SARASA | Kroma Kill | Stream | 43.00583 | -73.6173 | 2019-06-13 | 3852 | 2019 | 6 | 164 | NETN_LS |
| SARA | Saratoga National Historical Park | SARASA | Kroma Kill | Stream | 43.00583 | -73.6173 | 2019-07-16 | 3892 | 2019 | 7 | 197 | NETN_LS |
| SARA | Saratoga National Historical Park | SARASA | Kroma Kill | Stream | 43.00583 | -73.6173 | 2019-08-08 | 3920 | 2019 | 8 | 220 | NETN_LS |
| SARA | Saratoga National Historical Park | SARASA | Kroma Kill | Stream | 43.00583 | -73.6173 | 2019-09-11 | 3963 | 2019 | 9 | 254 | NETN_LS |
| SARA | Saratoga National Historical Park | SARASA | Kroma Kill | Stream | 43.00583 | -73.6173 | 2019-10-09 | 4005 | 2019 | 10 | 282 | NETN_LS |
Get info for all ACAD lakes sampled in April
ACAD_lake <- getEvents(park = 'ACAD', site_type = 'lake', months = 4, event_type = 'all')
print_head(ACAD_lake) # top 6 rows
| UnitCode | UnitName | SiteCode | SiteName | SiteType | SiteLatitude | SiteLongitude | EventDate | EventCode | year | month | doy | Project |
|---|---|---|---|---|---|---|---|---|---|---|---|---|
| ACAD | Acadia National Park | ACBUBL | Bubble Pond | Lake | 44.34506 | -68.23886 | 2006-04-12 | 4 | 2006 | 4 | 102 | ACAD_ACID |
| ACAD | Acadia National Park | ACBUBL | Bubble Pond | Lake | 44.34506 | -68.23886 | 2008-04-24 | 380 | 2008 | 4 | 115 | ACAD_ACID |
| ACAD | Acadia National Park | ACBUBL | Bubble Pond | Lake | 44.34506 | -68.23886 | 2009-04-23 | 1127 | 2009 | 4 | 113 | ACAD_ACID |
| ACAD | Acadia National Park | ACBUBL | Bubble Pond | Lake | 44.34506 | -68.23886 | 2010-04-21 | 143 | 2010 | 4 | 111 | ACAD_ACID |
| ACAD | Acadia National Park | ACBUBL | Bubble Pond | Lake | 44.34506 | -68.23886 | 2011-04-19 | 1515 | 2011 | 4 | 109 | ACAD_ACID |
| ACAD | Acadia National Park | ACBUBL | Bubble Pond | Lake | 44.34506 | -68.23886 | 2012-04-30 | 1374 | 2012 | 4 | 121 | ACAD_ACID |
This function allows you to query the Chemistry_Data view by park, site, site type, year, month, parameter, and sample type. The returned data frame is long (i.e. stacked) to facilitate data summary and plotting. Note that sample depth is not a filter in getChemistry() as it is with the Sonde In Situ data.
Get N parameters for all sites and non-QAQC events in MIMA.
Note that QC_type = "0" is the default for this
function, which returns only non-QAQC events. Note also the use of named
objects for the arguments. This allows you to set them at the top of a
script, rather than having to type them out repeatedly. You can then
change them in 1 place (i.e., update the year to 2024) and rerun the
code.
n_params <- c("NH3", "NH3_mgL", "NO2", "NO2_mgL", "NO2+NO3",
"NO2+NO3_mgL", "NO3", "NO3_ueqL", "TN", "TN_mgL")
period <- 2006:2023
mima_n <- getChemistry(park = "MIMA", years = period, parameter = n_params)
print_head(mima_n) # top 6 rows
| SiteCode | SiteName | UnitCode | SubUnitCode | EventDate | EventCode | Project | year | month | doy | datetime | QCtype | SampleType | SampleTime | SampleDepth_m | Parameter | Value | ValueFlag | ValueUnit | ValueDetectionCondition | censored | LabCode |
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| MIMASA | Mill Brook | MIMA | NA | 2006-08-21 | 766 | NETN_LS | 2006 | 8 | 233 | 2006-08-21 12:45:00 | ENV | G | 12:45:00 | 0.2 | TN_mgL | 0.560 | NA | mg/L | Detected and Quantified | FALSE | NWQL |
| MIMASA | Mill Brook | MIMA | NA | 2006-08-21 | 766 | NETN_LS | 2006 | 8 | 233 | 2006-08-21 12:45:00 | ENV | G | 12:45:00 | 0.2 | NO2+NO3_mgL | 0.169 | NA | mg/L | Detected and Quantified | FALSE | NWQL |
| MIMASA | Mill Brook | MIMA | NA | 2006-08-21 | 766 | NETN_LS | 2006 | 8 | 233 | 2006-08-21 12:45:00 | ENV | G | 12:45:00 | 0.2 | NO2_mgL | 0.002 | NA | mg/L | Detected and Quantified | FALSE | NWQL |
| MIMASA | Mill Brook | MIMA | NA | 2006-08-21 | 766 | NETN_LS | 2006 | 8 | 233 | 2006-08-21 12:45:00 | ENV | G | 12:45:00 | 0.2 | NH3_mgL | 0.030 | NA | mg/L | Detected and Quantified | FALSE | NWQL |
| MIMASA | Mill Brook | MIMA | NA | 2007-05-07 | 770 | NETN_LS | 2007 | 5 | 127 | 2007-05-07 12:31:00 | ENV | G | 12:31:00 | 0.2 | TN_mgL | 0.840 | NA | mg/L | Detected and Quantified | FALSE | NWQL |
| MIMASA | Mill Brook | MIMA | NA | 2007-05-07 | 770 | NETN_LS | 2007 | 5 | 127 | 2007-05-07 12:31:00 | ENV | G | 12:31:00 | 0.2 | NO2+NO3_mgL | 0.338 | NA | mg/L | Detected and Quantified | FALSE | NWQL |
Get chemistry data for all sites and all parameters in MABI from 2021-2023
mabi <- getChemistry(park = "MABI", years = 2021:2023)
print_head(mabi)# top 6 rows
| SiteCode | SiteName | UnitCode | SubUnitCode | EventDate | EventCode | Project | year | month | doy | datetime | QCtype | SampleType | SampleTime | SampleDepth_m | Parameter | Value | ValueFlag | ValueUnit | ValueDetectionCondition | censored | LabCode |
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| MABIPA | The Pogue | MABI | NA | 2021-05-24 | 4178 | NETN_LS | 2021 | 5 | 144 | 2021-05-24 10:42:33 | ENV | G | 10:42:33 | 0.5 | TN_mgL | 0.241 | NA | mg/L | Detected and Quantified | FALSE | SWRL |
| MABIPA | The Pogue | MABI | NA | 2021-05-24 | 4178 | NETN_LS | 2021 | 5 | 144 | 2021-05-24 10:42:33 | ENV | G | 10:42:33 | 0.5 | ChlA_ugL | 2.800 | NA | ug/L | Detected and Quantified | FALSE | SWRL |
| MABIPA | The Pogue | MABI | NA | 2021-05-24 | 4178 | NETN_LS | 2021 | 5 | 144 | 2021-05-24 10:42:33 | ENV | G | 10:42:33 | 0.5 | TP_ugL | 8.200 | NA | ug/L | Detected and Quantified | FALSE | SWRL |
| MABIPA | The Pogue | MABI | NA | 2021-06-22 | 4192 | NETN_LS | 2021 | 6 | 173 | 2021-06-22 16:17:35 | ENV | G | 16:17:35 | 0.5 | ChlA_ugL | 1.400 | NA | ug/L | Detected and Quantified | FALSE | SWRL |
| MABIPA | The Pogue | MABI | NA | 2021-06-22 | 4192 | NETN_LS | 2021 | 6 | 173 | 2021-06-22 16:17:35 | ENV | G | 16:17:35 | 0.5 | TN_mgL | 0.332 | NA | mg/L | Detected and Quantified | FALSE | SWRL |
| MABIPA | The Pogue | MABI | NA | 2021-06-22 | 4192 | NETN_LS | 2021 | 6 | 173 | 2021-06-22 16:17:35 | ENV | G | 16:17:35 | 0.5 | TP_ugL | 9.100 | NA | ug/L | Detected and Quantified | FALSE | SWRL |
Get lab pH for all sites in MIMA and SAIR. Note that by not specifying years, all years by default will be included in the output.
ma_parks <- getChemistry(park = c("SAIR", "MIMA"), parameter = "pH_Lab")
print_head(ma_parks)# top 6 rows
| SiteCode | SiteName | UnitCode | SubUnitCode | EventDate | EventCode | Project | year | month | doy | datetime | QCtype | SampleType | SampleTime | SampleDepth_m | Parameter | Value | ValueFlag | ValueUnit | ValueDetectionCondition | censored | LabCode |
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| MIMASA | Mill Brook | MIMA | NA | 2007-05-07 | 770 | NETN_LS | 2007 | 5 | 127 | 2007-05-07 12:31:00 | ENV | G | 12:31:00 | 0.2 | pH_Lab | 7.08 | NA | pH std units | Detected and Quantified | FALSE | SECRL |
| MIMASA | Mill Brook | MIMA | NA | 2007-08-13 | 773 | NETN_LS | 2007 | 8 | 225 | 2007-08-13 12:45:00 | ENV | G | 12:45:00 | 0.2 | pH_Lab | 7.15 | NA | pH std units | Detected and Quantified | FALSE | SECRL |
| MIMASA | Mill Brook | MIMA | NA | 2008-05-19 | 1115 | NETN_LS | 2008 | 5 | 140 | NA | ENV | G | NA | 0.2 | pH_Lab | 7.27 | NA | pH std units | Detected and Quantified | FALSE | SECRL |
| MIMASA | Mill Brook | MIMA | NA | 2008-08-20 | 776 | NETN_LS | 2008 | 8 | 233 | NA | ENV | G | NA | 0.2 | pH_Lab | 7.00 | NA | pH std units | Detected and Quantified | FALSE | SECRL |
| MIMASA | Mill Brook | MIMA | NA | 2009-05-08 | 1204 | NETN_LS | 2009 | 5 | 128 | NA | ENV | G | NA | 0.2 | pH_Lab | 6.88 | NA | pH std units | Detected and Quantified | FALSE | SECRL |
| MIMASA | Mill Brook | MIMA | NA | 2009-08-19 | 1232 | NETN_LS | 2009 | 8 | 231 | NA | ENV | G | NA | 0.2 | pH_Lab | 7.46 | NA | pH std units | Detected and Quantified | FALSE | SECRL |
Get chemistry for all ACAD lakes sampled in April for acidification.
ACAD_lake<- getChemistry(park = 'ACAD', site_type = 'lake', months = 4, event_type = 'all')
print_head(ACAD_lake)# top 6 rows
| SiteCode | SiteName | UnitCode | SubUnitCode | EventDate | EventCode | Project | year | month | doy | datetime | QCtype | SampleType | SampleTime | SampleDepth_m | Parameter | Value | ValueFlag | ValueUnit | ValueDetectionCondition | censored | LabCode |
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| ACBUBL | Bubble Pond | ACAD | NA | 2006-04-12 | 4 | ACAD_ACID | 2006 | 4 | 102 | NA | ENV | G | NA | 0.2 | ANC_ueqL | 46.40 | NA | ueq/L | Detected and Quantified | FALSE | GMC |
| ACBUBL | Bubble Pond | ACAD | NA | 2006-04-12 | 4 | ACAD_ACID | 2006 | 4 | 102 | NA | ENV | G | NA | 0.2 | Cl_ueqL | 127.60 | NA | ueq/L | Detected and Quantified | FALSE | GMC |
| ACBUBL | Bubble Pond | ACAD | NA | 2006-04-12 | 4 | ACAD_ACID | 2006 | 4 | 102 | NA | ENV | G | NA | 0.2 | DOC_mgL | 2.30 | NA | mg/L | Detected and Quantified | FALSE | GMC |
| ACBUBL | Bubble Pond | ACAD | NA | 2006-04-12 | 4 | ACAD_ACID | 2006 | 4 | 102 | NA | ENV | G | NA | 0.2 | NO3_ueqL | 1.30 | NA | ueq/L | Detected and Quantified | FALSE | GMC |
| ACBUBL | Bubble Pond | ACAD | NA | 2006-04-12 | 4 | ACAD_ACID | 2006 | 4 | 102 | NA | ENV | G | NA | 0.2 | pH_Lab | 6.42 | NA | pH std units | Detected and Quantified | FALSE | GMC |
| ACBUBL | Bubble Pond | ACAD | NA | 2006-04-12 | 4 | ACAD_ACID | 2006 | 4 | 102 | NA | ENV | G | NA | 0.2 | SO4_ueqL | 56.80 | NA | ueq/L | Detected and Quantified | FALSE | GMC |
Get ANC for lower NETN parks from May to Oct.
lnetn <- c("MABI", "MIMA", "MORR", "ROVA", "SAGA", "SAIR", "SARA", "WEFA")
anc <- getChemistry(park = lnetn, parameter = "ANC_ueqL", months = 5:10)
print_head(anc)# top 6 rows
| SiteCode | SiteName | UnitCode | SubUnitCode | EventDate | EventCode | Project | year | month | doy | datetime | QCtype | SampleType | SampleTime | SampleDepth_m | Parameter | Value | ValueFlag | ValueUnit | ValueDetectionCondition | censored | LabCode |
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| MABIPA | The Pogue | MABI | NA | 2006-06-13 | 1330 | NETN_LS | 2006 | 6 | 164 | 2006-06-13 15:30:00 | ENV | G | 15:30:00 | 0.2 | ANC_ueqL | 1640.0 | NA | ueq/L | Detected and Quantified | FALSE | NWQL |
| MABIPA | The Pogue | MABI | NA | 2006-08-23 | 1331 | NETN_LS | 2006 | 8 | 235 | 2006-08-23 10:45:00 | ENV | G | 10:45:00 | 0.2 | ANC_ueqL | 1660.0 | NA | ueq/L | Detected and Quantified | FALSE | NWQL |
| MABIPA | The Pogue | MABI | NA | 2007-06-07 | 1058 | NETN_LS | 2007 | 6 | 158 | 2007-06-07 14:30:00 | ENV | G | 14:30:00 | 0.2 | ANC_ueqL | 1654.0 | NA | ueq/L | Detected and Quantified | FALSE | SECRL |
| MABIPA | The Pogue | MABI | NA | 2007-08-14 | 1060 | NETN_LS | 2007 | 8 | 226 | 2007-08-14 14:20:00 | ENV | G | 14:20:00 | 0.2 | ANC_ueqL | 1614.8 | NA | ueq/L | Detected and Quantified | FALSE | SECRL |
| MABIPA | The Pogue | MABI | NA | 2008-06-17 | 1101 | NETN_LS | 2008 | 6 | 169 | NA | ENV | G | NA | 0.2 | ANC_ueqL | 1496.0 | NA | ueq/L | Detected and Quantified | FALSE | SECRL |
| MABIPA | The Pogue | MABI | NA | 2008-08-22 | 1063 | NETN_LS | 2008 | 8 | 235 | NA | ENV | G | NA | 0.2 | ANC_ueqL | 1380.0 | NA | ueq/L | Detected and Quantified | FALSE | SECRL |
Get censored and non-censored NH3 data for LNETN all years. Note the Flag column indicates the measurement is censored by reporting the detection limit used.
lnetn <- c("MABI", "MIMA", "MORR", "ROVA", "SAGA", "SAIR", "SARA", "WEFA")
nh3_cen <- getChemistry(park = lnetn, parameter = "NH3_mgL", include_censored = T)
print_head(nh3_cen)# top 6 rows
| SiteCode | SiteName | UnitCode | SubUnitCode | EventDate | EventCode | Project | year | month | doy | datetime | QCtype | SampleType | SampleTime | SampleDepth_m | Parameter | Value | ValueFlag | ValueUnit | ValueDetectionCondition | censored | LabCode |
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| MABIPA | The Pogue | MABI | NA | 2006-06-13 | 1330 | NETN_LS | 2006 | 6 | 164 | 2006-06-13 15:30:00 | ENV | G | 15:30:00 | 0.2 | NH3_mgL | 0.006 | E, <MRL 0.01 | mg/L | Detected and Quantified | FALSE | NWQL |
| MABIPA | The Pogue | MABI | NA | 2006-08-23 | 1331 | NETN_LS | 2006 | 8 | 235 | 2006-08-23 10:45:00 | ENV | G | 10:45:00 | 0.2 | NH3_mgL | 0.068 | NA | mg/L | Detected and Quantified | FALSE | NWQL |
| MABIPA | The Pogue | MABI | NA | 2007-06-07 | 1058 | NETN_LS | 2007 | 6 | 158 | 2007-06-07 14:30:00 | ENV | G | 14:30:00 | 0.2 | NH3_mgL | 0.053 | NA | mg/L | Detected and Quantified | FALSE | NWQL |
| MABIPA | The Pogue | MABI | NA | 2007-08-14 | 1060 | NETN_LS | 2007 | 8 | 226 | 2007-08-14 14:20:00 | ENV | G | 14:20:00 | 0.2 | NH3_mgL | 0.099 | NA | mg/L | Detected and Quantified | FALSE | NWQL |
| MABIPA | The Pogue | MABI | NA | 2008-06-17 | 1101 | NETN_LS | 2008 | 6 | 169 | NA | ENV | G | NA | 0.2 | NH3_mgL | NA | <MRL 0.08 | mg/L | Present Below Quantification Limit | FALSE | SECRL |
| MABIPA | The Pogue | MABI | NA | 2008-08-22 | 1063 | NETN_LS | 2008 | 8 | 235 | NA | ENV | G | NA | 0.2 | NH3_mgL | NA | <MRL 0.08 | mg/L | Present Below Quantification Limit | FALSE | SECRL |
This function allows you to query the Discharge_Data view by park, site, site type, year, month, measurement method (e.g., flowtracker or pygmy), and measurement rating (e.g., E, G, F, P). Note that you can also return all columns or a reduced set of columns with the output argument. Default is output = ‘short’. This function is set up to work with site_type = ‘stream’, so you don’t have to specify that.
Get discharge for all sites in SARA from 2022-2024
sara <- getDischarge(park = "SARA", years = 2022:2024)
print_head(sara)# top 6 rows
| SiteCode | SiteName | UnitCode | SubUnitCode | EventDate | EventCode | Project | year | month | doy | ReachType | FlowStatus | DischargeMethod | TotalArea_sqft | AvgVel_fs | VelocityFlag | Discharge_cfs | DischargeFlag | MeasurementRating | Comments |
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| SARASA | Kroma Kill | SARA | NA | 2022-05-25 | 4422 | NETN_LS | 2022 | 5 | 145 | Run | Stable | Flowtracker | 9.48 | 0.25 | NA | 2.35 | NA | F | From 5-9ft concentrated flow and swirling in center of channel; best site available given flow levels. |
| SARASA | Kroma Kill | SARA | NA | 2022-06-14 | 4464 | NETN_LS | 2022 | 6 | 165 | Run | Stable | Flowtracker | 8.17 | 0.33 | NA | 2.69 | NA | F | Control is the shale rock bed bars about 6ft downstream of tag line. |
| SARASA | Kroma Kill | SARA | NA | 2022-07-19 | 4508 | NETN_LS | 2022 | 7 | 200 | Chute | Stable | Flowtracker | 1.19 | 0.44 | NA | 0.53 | NA | P | Chute only spot with enough flow and depth to run flowtracker. Control is rockbed about 1 foot downstream. |
| SARASA | Kroma Kill | SARA | NA | 2022-08-22 | 4540 | NETN_LS | 2022 | 8 | 234 | Run | Rising | Flowtracker | 7.19 | 0.04 | NA | 0.31 | NA | F | Needed to move flowtracker measurement again, too shallow to repeat where taken at last visit. Water moving slow on |
| SARASA | Kroma Kill | SARA | NA | 2022-09-15 | 4592 | NETN_LS | 2022 | 9 | 258 | Run | Falling | Flowtracker | 0.96 | 1.60 | NA | 1.54 | NA | P | Control is opening of stream into pool about 3-4ft downstream of tagline. Velocity errors, flow over rocks must have interfered. |
| SARASA | Kroma Kill | SARA | NA | 2022-10-20 | 4635 | NETN_LS | 2022 | 10 | 293 | Run | Stable | Flowtracker | 1.29 | 1.53 | NA | 1.98 | NA | F | Struggled to find a better flow tracker spot. Control seems to be curves of stream. |
Get discharge for ACAD streams in July 2023
acad_dis <- getDischarge(park = "ACAD", years = 2023, months = 7)
print_head(acad_dis)# top 6 rows
| SiteCode | SiteName | UnitCode | SubUnitCode | EventDate | EventCode | Project | year | month | doy | ReachType | FlowStatus | DischargeMethod | TotalArea_sqft | AvgVel_fs | VelocityFlag | Discharge_cfs | DischargeFlag | MeasurementRating | Comments |
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| ACBRWN | Browns Brook | ACAD | NA | 2023-07-05 | 4747 | NETN_LS | 2023 | 7 | 186 | Run | Falling | Flowtracker | 2.01 | 0.67 | NA | 1.35 | NA | F | None |
| ACCADS | Cadillac Stream | ACAD | NA | 2023-07-11 | 4754 | NETN_LS | 2023 | 7 | 192 | NA | Stable | Rating curve estimate | NA | NA | NA | 0.31 | NA | NA | 1.050+0.30=1.350 0.961+0.39=1.351 |
| ACDKLI | Duck Pond Brook | ACAD | NA | 2023-07-06 | 4751 | NETN_LS | 2023 | 7 | 187 | Run | Stable | Flowtracker | 2.88 | 0.13 | NA | 0.39 | NA | F | None |
| ACDUCK | Duck Brook | ACAD | NA | 2023-07-10 | 4753 | NETN_LS | 2023 | 7 | 191 | Run | Stable | Flowtracker | 5.52 | 1.16 | NA | 6.43 | NA | F | None |
| ACHADB | Hadlock Brook | ACAD | NA | 2023-07-12 | 4756 | NETN_LS | 2023 | 7 | 193 | NA | Stable | Rating curve estimate | NA | NA | NA | 0.17 | NA | NA | RP1: 4.964-1.19= 3.774 RM2: 3.604+0.17=3.774 RM3: 3.218 0.56= 3.77 |
| ACLKWO | Lake Wood Outlet | ACAD | NA | 2023-07-06 | 4752 | NETN_LS | 2023 | 7 | 187 | Run | Stable | Flowtracker | 3.69 | 0.33 | NA | 1.22 | NA | G | None |
Get discharge measured with Flowtracker
flow <- getDischarge(method = c("Flowtracker"))
print_head(flow)# top 6 rows
| SiteCode | SiteName | UnitCode | SubUnitCode | EventDate | EventCode | Project | year | month | doy | ReachType | FlowStatus | DischargeMethod | TotalArea_sqft | AvgVel_fs | VelocityFlag | Discharge_cfs | DischargeFlag | MeasurementRating | Comments |
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| ACABIN | Aunt Betty Pond Inlet | ACAD | NA | 2014-05-13 | 2485 | NETN_LS | 2014 | 5 | 133 | Run | NA | Flowtracker | 6.29 | 0.12 | NA | 0.74 | NA | NA | NA |
| ACABIN | Aunt Betty Pond Inlet | ACAD | NA | 2014-06-05 | 2484 | NETN_LS | 2014 | 6 | 156 | Run | NA | Flowtracker | 5.68 | 0.05 | NA | 0.27 | NA | NA | NA |
| ACABIN | Aunt Betty Pond Inlet | ACAD | NA | 2014-07-14 | 2488 | NETN_LS | 2014 | 7 | 195 | Run | NA | Flowtracker | 5.61 | 0.04 | NA | 0.24 | NA | NA | NA |
| ACABIN | Aunt Betty Pond Inlet | ACAD | NA | 2014-08-14 | 2489 | NETN_LS | 2014 | 8 | 226 | Run | NA | Flowtracker | 8.08 | 0.17 | NA | 1.35 | NA | NA | SNR’s differed btw beams |
| ACABIN | Aunt Betty Pond Inlet | ACAD | NA | 2016-05-10 | 3137 | NETN_LS | 2016 | 5 | 131 | Run | Rising | Flowtracker | 5.72 | 0.31 | NA | 1.76 | NA | NA | None. |
| ACABIN | Aunt Betty Pond Inlet | ACAD | NA | 2016-06-06 | 3141 | NETN_LS | 2016 | 6 | 158 | Run | Rising | Flowtracker | 8.91 | 0.45 | NA | 3.98 | NA | NA | None. |
Get excellent rated measurements only for MIMA
exc <- getDischarge(park = "MIMA", rating = "E")
print_head(exc)# top 6 rows
| SiteCode | SiteName | UnitCode | SubUnitCode | EventDate | EventCode | Project | year | month | doy | ReachType | FlowStatus | DischargeMethod | TotalArea_sqft | AvgVel_fs | VelocityFlag | Discharge_cfs | DischargeFlag | MeasurementRating | Comments |
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| MIMASA | Mill Brook | MIMA | NA | 2018-05-04 | 3522 | NETN_LS | 2018 | 5 | 124 | Run | Falling | Flowtracker | 6.87 | 0.69 | NA | 4.70 | NA | E | Even flow |
| MIMASA | Mill Brook | MIMA | NA | 2021-07-06 | 4250 | NETN_LS | 2021 | 7 | 187 | Run | Falling | Flowtracker | 20.87 | 0.50 | NA | 10.43 | NA | E | Hugh discharge due to recent rains |
| MIMASA | Mill Brook | MIMA | NA | 2021-09-10 | 4329 | NETN_LS | 2021 | 9 | 253 | Run | Stable | Flowtracker | 18.64 | 0.49 | NA | 9.20 | NA | E | Very high flow due to recent rain storms |
| MIMASA | Mill Brook | MIMA | NA | 2022-10-19 | 4632 | NETN_LS | 2022 | 10 | 292 | Run | Stable | Flowtracker | 14.84 | 0.48 | NA | 7.09 | NA | E | None |
| MIMASA | Mill Brook | MIMA | NA | 2023-06-06 | 4717 | NETN_LS | 2023 | 6 | 157 | Run | Falling | Flowtracker | 19.45 | 0.67 | NA | 12.96 | NA | E | No FlowTracker errors, had even, straight banks, decent amount of water. |
| MIMASA | Mill Brook | MIMA | NA | 2023-07-05 | 4758 | NETN_LS | 2023 | 7 | 186 | Run | Stable | Flowtracker | 20.45 | 0.62 | NA | 12.77 | NA | E | Great measurement. Only one error and 29 bins. |
This function allows you to query the Light_Penetration_Data view by park, site, site type, year, and month. Again output = ‘short’ is the default. If specify output = ‘verbose’, you’ll get all possible columns. This is only set up to work with site_type = ‘lake’, so you don’t have to specify that.
Get light penetration for the Pogue in MABI from 2021-2023.
mabi <- getLightPen(site = "MABIPA", years = 2021:2023)
print_head(mabi)# top 6 rows
| SiteCode | SiteName | UnitCode | SubUnitCode | EventDate | EventCode | Project | year | month | doy | MeasurementTime | MeasurementDepth_m | LightDeck | LightUW | PenetrationRatio |
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| MABIPA | The Pogue | MABI | NA | 2021-05-24 | 4178 | NETN_LS | 2021 | 5 | 144 | 11:17:51 | 0.10 | 2009.6 | 2198.80 | 1.09410 |
| MABIPA | The Pogue | MABI | NA | 2021-05-24 | 4178 | NETN_LS | 2021 | 5 | 144 | 11:20:00 | 0.25 | 1861.2 | 1812.80 | 0.97403 |
| MABIPA | The Pogue | MABI | NA | 2021-05-24 | 4178 | NETN_LS | 2021 | 5 | 144 | 11:20:49 | 0.50 | 1965.9 | 1424.30 | 0.72451 |
| MABIPA | The Pogue | MABI | NA | 2021-05-24 | 4178 | NETN_LS | 2021 | 5 | 144 | 11:21:56 | 0.75 | 1906.9 | 1102.30 | 0.57807 |
| MABIPA | The Pogue | MABI | NA | 2021-05-24 | 4178 | NETN_LS | 2021 | 5 | 144 | 11:22:29 | 1.00 | 1963.9 | 1081.30 | 0.55059 |
| MABIPA | The Pogue | MABI | NA | 2021-05-24 | 4178 | NETN_LS | 2021 | 5 | 144 | 11:22:56 | 1.25 | 1941.3 | 963.28 | 0.49621 |
Get light penetration for all ACAD lakes sampled in August.
acad <- getLightPen(park = 'ACAD', months = 8)
print_head(acad) # top 6 rows
| SiteCode | SiteName | UnitCode | SubUnitCode | EventDate | EventCode | Project | year | month | doy | MeasurementTime | MeasurementDepth_m | LightDeck | LightUW | PenetrationRatio |
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| ACANTB | Aunt Bettys Pond | ACAD | NA | 2006-08-09 | 48 | NETN_LS | 2006 | 8 | 221 | 11:25:53 | 0.10 | 1708.7 | 1428.700 | 0.840030 |
| ACANTB | Aunt Bettys Pond | ACAD | NA | 2006-08-09 | 48 | NETN_LS | 2006 | 8 | 221 | 11:27:04 | 0.50 | 1747.9 | 533.940 | 0.305670 |
| ACANTB | Aunt Bettys Pond | ACAD | NA | 2006-08-09 | 48 | NETN_LS | 2006 | 8 | 221 | 11:28:15 | 1.00 | 1678.9 | 209.400 | 0.125140 |
| ACANTB | Aunt Bettys Pond | ACAD | NA | 2006-08-09 | 48 | NETN_LS | 2006 | 8 | 221 | 11:29:49 | 1.75 | 1728.1 | 60.852 | 0.035237 |
| ACANTB | Aunt Bettys Pond | ACAD | NA | 2009-08-25 | 730 | NETN_LS | 2009 | 8 | 237 | 14:53:26 | 0.10 | 1518.0 | 749.500 | 0.493740 |
| ACANTB | Aunt Bettys Pond | ACAD | NA | 2009-08-25 | 730 | NETN_LS | 2009 | 8 | 237 | 14:54:25 | 0.50 | 1519.4 | 116.960 | 0.076982 |
Get light penetration for the given ACAD sites related to the ACAD_ACID project.
acad_acid <- getChemistry(site = c("ACJORD", "ACEAGL", "ACBUBL"), event_type = "acid")
print_head(acad_acid) # top 6 rows
| SiteCode | SiteName | UnitCode | SubUnitCode | EventDate | EventCode | Project | year | month | doy | datetime | QCtype | SampleType | SampleTime | SampleDepth_m | Parameter | Value | ValueFlag | ValueUnit | ValueDetectionCondition | censored | LabCode |
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| ACBUBL | Bubble Pond | ACAD | NA | 2006-10-17 | 71 | NETN+ACID | 2006 | 10 | 290 | NA | ENV | G | NA | 0.2 | NO3_ueqL | NA | <MRL 1 | ueq/L | Present Below Quantification Limit | FALSE | SECRL |
| ACBUBL | Bubble Pond | ACAD | NA | 2006-10-17 | 71 | NETN+ACID | 2006 | 10 | 290 | NA | ENV | G | NA | 0.2 | ANC_ueqL | 65.600 | NA | ueq/L | Detected and Quantified | FALSE | SECRL |
| ACBUBL | Bubble Pond | ACAD | NA | 2006-10-17 | 71 | NETN+ACID | 2006 | 10 | 290 | NA | ENV | G | NA | 0.2 | DOC_mgL | 2.410 | NA | mg/L | Detected and Quantified | FALSE | SECRL |
| ACBUBL | Bubble Pond | ACAD | NA | 2006-10-17 | 71 | NETN+ACID | 2006 | 10 | 290 | NA | ENV | G | NA | 0.2 | pH_Lab | 6.450 | NA | pH std units | Detected and Quantified | FALSE | SECRL |
| ACBUBL | Bubble Pond | ACAD | NA | 2006-10-17 | 71 | NETN+ACID | 2006 | 10 | 290 | NA | ENV | G | NA | 0.2 | SO4_ueqL | 64.400 | NA | ueq/L | Detected and Quantified | FALSE | SECRL |
| ACBUBL | Bubble Pond | ACAD | NA | 2006-10-17 | 71 | NETN+ACID | 2006 | 10 | 290 | NA | ENV | G | NA | 0.2 | TN_mgL | 0.118 | NA | mg/L | Detected and Quantified | FALSE | SECRL |
Get Secchi depth the Pogue from 2021-2023, first observer only
mabi <- getSecchi(site = "MABIPA", years = 2021:2023, observer_type = "first")
print_head(mabi)# top 6 rows
| SiteCode | SiteName | UnitCode | SubUnitCode | EventDate | EventCode | Project | year | month | doy | Parameter | Value | SD_HitBottom | Observer |
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| MABIPA | The Pogue | MABI | NA | 2021-05-24 | 4178 | NETN_LS | 2021 | 5 | 144 | SecchiDepth_m | 2.80 | TRUE | 1 |
| MABIPA | The Pogue | MABI | NA | 2021-06-22 | 4192 | NETN_LS | 2021 | 6 | 173 | SecchiDepth_m | 3.00 | TRUE | 1 |
| MABIPA | The Pogue | MABI | NA | 2021-07-20 | 4239 | NETN_LS | 2021 | 7 | 201 | SecchiDepth_m | 2.90 | TRUE | 1 |
| MABIPA | The Pogue | MABI | NA | 2021-08-25 | 4281 | NETN_LS | 2021 | 8 | 237 | SecchiDepth_m | 3.01 | TRUE | 1 |
| MABIPA | The Pogue | MABI | NA | 2021-09-21 | 4315 | NETN_LS | 2021 | 9 | 264 | SecchiDepth_m | 3.05 | TRUE | 1 |
| MABIPA | The Pogue | MABI | NA | 2021-10-22 | 4349 | NETN_LS | 2021 | 10 | 295 | SecchiDepth_m | 2.85 | TRUE | 1 |
Get Secchi for all ACAD lakes sampled in July for all observers
ACAD_lake <- getSecchi(park = 'ACAD', months = 7)
print_head(ACAD_lake)# top 6 rows
| SiteCode | SiteName | UnitCode | SubUnitCode | EventDate | EventCode | Project | year | month | doy | Parameter | Value | SD_HitBottom | Observer |
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| ACANTB | Aunt Bettys Pond | ACAD | NA | 2006-07-13 | 38 | NETN_LS | 2006 | 7 | 194 | SecchiDepth_m | 1.95 | TRUE | 1 |
| ACANTB | Aunt Bettys Pond | ACAD | NA | 2009-07-23 | 1136 | NETN_LS | 2009 | 7 | 204 | SecchiDepth_m | 2.34 | TRUE | 1 |
| ACANTB | Aunt Bettys Pond | ACAD | NA | 2012-07-24 | 1389 | NETN_LS | 2012 | 7 | 206 | SecchiDepth_m | 2.44 | FALSE | 1 |
| ACANTB | Aunt Bettys Pond | ACAD | NA | 2015-07-30 | 2717 | NETN_LS | 2015 | 7 | 211 | SecchiDepth_m | 2.25 | TRUE | 1 |
| ACANTB | Aunt Bettys Pond | ACAD | NA | 2018-07-20 | 3617 | NETN_LS | 2018 | 7 | 201 | SecchiDepth_m | 2.05 | TRUE | 1 |
| ACANTB | Aunt Bettys Pond | ACAD | NA | 2021-07-19 | 4231 | NETN_LS | 2021 | 7 | 200 | SecchiDepth_m | 1.60 | TRUE | 1 |
Get the long version of Secchi depth for all LNETN parks from May to October
lnetn <- c("MABI", "MIMA", "MORR", "ROVA", "SAGA", "SAIR", "SARA", "WEFA")
lnetn_secchi <- getSecchi(park = lnetn, months = 5:10, output = "verbose")
print_head(lnetn_secchi)# top 6 rows
| SiteCode | SiteType | EventDate | EventCode | Project | GroupCode | GroupName | UnitCode | UnitName | SubUnitCode | SubUnitName | SiteName | Parameter | Value | SD_HitBottom | ObsInit | IsEventCUI | year | month | doy | Observer |
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| MABIPA | Lake | 2006-07-20 | 671 | NETN_LS | NETN | Northeast Temperate Network | MABI | Marsh-Billings-Rockefeller National Historical Park | NA | NA | The Pogue | SecchiDepth_m | 2.00 | FALSE | NA | FALSE | 2006 | 7 | 201 | 1 |
| MABIPA | Lake | 2010-05-25 | 292 | NETN_LS | NETN | Northeast Temperate Network | MABI | Marsh-Billings-Rockefeller National Historical Park | NA | NA | The Pogue | SecchiDepth_m | 2.75 | TRUE | DF | FALSE | 2010 | 5 | 145 | 1 |
| MABIPA | Lake | 2010-06-15 | 293 | NETN_LS | NETN | Northeast Temperate Network | MABI | Marsh-Billings-Rockefeller National Historical Park | NA | NA | The Pogue | SecchiDepth_m | 2.70 | TRUE | NA | FALSE | 2010 | 6 | 166 | 1 |
| MABIPA | Lake | 2010-07-08 | 291 | NETN_LS | NETN | Northeast Temperate Network | MABI | Marsh-Billings-Rockefeller National Historical Park | NA | NA | The Pogue | SecchiDepth_m | 2.30 | TRUE | NA | FALSE | 2010 | 7 | 189 | 1 |
| MABIPA | Lake | 2010-08-11 | 290 | NETN_LS | NETN | Northeast Temperate Network | MABI | Marsh-Billings-Rockefeller National Historical Park | NA | NA | The Pogue | SecchiDepth_m | 3.22 | TRUE | NA | FALSE | 2010 | 8 | 223 | 1 |
| MABIPA | Lake | 2010-09-08 | 294 | NETN_LS | NETN | Northeast Temperate Network | MABI | Marsh-Billings-Rockefeller National Historical Park | NA | NA | The Pogue | SecchiDepth_m | 2.40 | TRUE | NA | FALSE | 2010 | 9 | 251 | 1 |
This function allows you to query Sonde in situ data by park, site, site type, years, months, parameter, QC type, surface vs. all, etc. Default returns all non-QAQC observations with data. The Sonde_InSitu_Data view is large and can take a few seconds to run for most parks, sites, years, parameters, etc. Surface only measurements, defined as as the medium of all samples within 2m of the surface, are the default.
Get Sonde data for all sites and parameters in MABI from 2021-2023 for non-QAQC samples
mabi <- getSondeInSitu(park = "MABI", years = 2021:2023)
print_head(mabi)# top 6 rows
| SiteCode | SiteName | UnitCode | SubUnitCode | EventDate | SiteType | Project | year | month | doy | datetime | QCtype | SampleDepth_m | Parameter | Value | ValueFlag | FlagComments |
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| MABIPA | The Pogue | MABI | NA | 2021-05-24 | Lake | NETN_LS | 2021 | 5 | 144 | 2021-05-24 12:00:00 | 0 | 0.97 | DO_mgL | 8.660 | NA | NA |
| MABIPA | The Pogue | MABI | NA | 2021-05-24 | Lake | NETN_LS | 2021 | 5 | 144 | 2021-05-24 12:00:00 | 0 | 0.97 | DOsat_pct | 97.400 | NA | NA |
| MABIPA | The Pogue | MABI | NA | 2021-05-24 | Lake | NETN_LS | 2021 | 5 | 144 | 2021-05-24 12:00:00 | 0 | 0.97 | SpCond_uScm | 186.400 | NA | NA |
| MABIPA | The Pogue | MABI | NA | 2021-05-24 | Lake | NETN_LS | 2021 | 5 | 144 | 2021-05-24 12:00:00 | 0 | 0.97 | Temp_C | 20.870 | NA | NA |
| MABIPA | The Pogue | MABI | NA | 2021-05-24 | Lake | NETN_LS | 2021 | 5 | 144 | 2021-05-24 12:00:00 | 0 | 0.97 | Temp_F | 69.566 | NA | NA |
| MABIPA | The Pogue | MABI | NA | 2021-05-24 | Lake | NETN_LS | 2021 | 5 | 144 | 2021-05-24 12:00:00 | 0 | 0.97 | Turbidity_FNU | 0.390 | NA | NA |
get data for all DO parameters in MIMA from 2006-2023 for non-QAQC samples
params <- c("DOsat_pct", "DOsatLoc_pct", "DO_mgL")
period <- 2006:2023
mima_do <- getSondeInSitu(park = "MIMA", years = period, parameter = params)
print_head(mima_do)# top 6 rows
| SiteCode | SiteName | UnitCode | SubUnitCode | EventDate | SiteType | Project | year | month | doy | datetime | QCtype | SampleDepth_m | Parameter | Value | ValueFlag | FlagComments |
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| MIMASA | Mill Brook | MIMA | NA | 2006-05-15 | Stream | NETN_LS | 2006 | 5 | 135 | 2006-05-15 12:00:00 | 0 | 0.13 | DO_mgL | 7.35 | NA | NA |
| MIMASA | Mill Brook | MIMA | NA | 2006-05-15 | Stream | NETN_LS | 2006 | 5 | 135 | 2006-05-15 12:00:00 | 0 | 0.13 | DOsat_pct | 64.90 | NA | NA |
| MIMASA | Mill Brook | MIMA | NA | 2006-06-12 | Stream | NETN_LS | 2006 | 6 | 163 | 2006-06-12 12:00:00 | 0 | 0.49 | DO_mgL | 6.38 | NA | NA |
| MIMASA | Mill Brook | MIMA | NA | 2006-06-12 | Stream | NETN_LS | 2006 | 6 | 163 | 2006-06-12 12:00:00 | 0 | 0.49 | DOsat_pct | 67.40 | NA | NA |
| MIMASA | Mill Brook | MIMA | NA | 2006-07-17 | Stream | NETN_LS | 2006 | 7 | 198 | 2006-07-17 12:00:00 | 0 | 0.23 | DO_mgL | 5.62 | NA | NA |
| MIMASA | Mill Brook | MIMA | NA | 2006-07-17 | Stream | NETN_LS | 2006 | 7 | 198 | 2006-07-17 12:00:00 | 0 | 0.23 | DOsat_pct | 64.00 | NA | NA |
Get Temp data for all sample depths in Jordan Pond in ACAD for non-QAQC samples
ACAD_lake <- getSondeInSitu(site = 'ACJORD', parameter = "Temp_C",
sample_depth = "all")
print_head(ACAD_lake)
| SiteCode | SiteName | UnitCode | SubUnitCode | EventDate | SiteType | Project | year | month | doy | datetime | QCtype | SampleDepth_m | Parameter | Value | ValueFlag | FlagComments |
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| ACJORD | Jordan Pond | ACAD | NA | 2006-05-23 | Lake | NETN_LS | 2006 | 5 | 143 | 2006-05-23 12:00:00 | 0 | 21.23 | Temp_C | 6.41 | NA | NA |
| ACJORD | Jordan Pond | ACAD | NA | 2006-05-23 | Lake | NETN_LS | 2006 | 5 | 143 | 2006-05-23 12:00:00 | 0 | 17.17 | Temp_C | 7.13 | NA | NA |
| ACJORD | Jordan Pond | ACAD | NA | 2006-05-23 | Lake | NETN_LS | 2006 | 5 | 143 | 2006-05-23 12:00:00 | 0 | 24.13 | Temp_C | 6.00 | NA | NA |
| ACJORD | Jordan Pond | ACAD | NA | 2006-05-23 | Lake | NETN_LS | 2006 | 5 | 143 | 2006-05-23 12:00:00 | 0 | 24.13 | Temp_C | 6.01 | NA | NA |
| ACJORD | Jordan Pond | ACAD | NA | 2006-05-23 | Lake | NETN_LS | 2006 | 5 | 143 | 2006-05-23 12:00:00 | 0 | 24.14 | Temp_C | 6.02 | NA | NA |
| ACJORD | Jordan Pond | ACAD | NA | 2006-05-23 | Lake | NETN_LS | 2006 | 5 | 143 | 2006-05-23 12:00:00 | 0 | 24.16 | Temp_C | 6.05 | NA | NA |
Get pH for lower NETN parks from May to Oct for QAQC and non-QAQC samples
lnetn_ph <- getSondeInSitu(park = "LNETN", param = "pH", months = 5:10,
QC_type = 'all')
print_head(lnetn_ph)# top 6 rows
| SiteCode | SiteName | UnitCode | SubUnitCode | EventDate | SiteType | Project | year | month | doy | datetime | QCtype | SampleDepth_m | Parameter | Value | ValueFlag | FlagComments |
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| MABIPA | The Pogue | MABI | NA | 2006-06-13 | Lake | NETN_LS | 2006 | 6 | 164 | 2006-06-13 12:00:00 | 0 | 0.990 | pH | 8.690 | NA | NA |
| MABIPA | The Pogue | MABI | NA | 2006-06-13 | Lake | NETN_LS | 2006 | 6 | 164 | 2006-06-13 12:00:00 | 999 | 0.000 | pH | 8.560 | NA | NA |
| MABIPA | The Pogue | MABI | NA | 2006-07-20 | Lake | NETN_LS | 2006 | 7 | 201 | 2006-07-20 12:00:00 | 0 | 0.990 | pH | 8.520 | NA | NA |
| MABIPA | The Pogue | MABI | NA | 2006-07-20 | Lake | NETN_LS | 2006 | 7 | 201 | 2006-07-20 12:00:00 | 999 | -0.162 | pH | 8.325 | NA | NA |
| MABIPA | The Pogue | MABI | NA | 2006-08-23 | Lake | NETN_LS | 2006 | 8 | 235 | 2006-08-23 12:00:00 | 0 | 1.000 | pH | 8.160 | NA | NA |
| MABIPA | The Pogue | MABI | NA | 2006-08-23 | Lake | NETN_LS | 2006 | 8 | 235 | 2006-08-23 12:00:00 | 899 | 0.000 | pH | 7.930 | NA | NA |
Get stream observations for Pogue Stream all years
mabi <- getStreamObs(park = "MABI")
print_head(mabi)# top 6 rows
| SiteCode | UnitCode | SubUnitCode | EventDate | EventCode | year | month | doy | WaterClarity | WaterColor | WaterCondition | AlgaeSlimeExtent | AlgaeSlimeAmount | AlgaeSlimeColor | AlgaeFilExtent | AlgaeFilColor | AlgaeClumpsExtent | AlgaeClumpsColor | Algae_Notes |
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| MABIPA | MABI | NA | 2013-05-06 | 2424 | 2013 | 5 | 126 | NA | NA | None | NA | NA | NA | NA | NA | NA | NA | None |
| MABIPA | MABI | NA | 2013-06-04 | 2423 | 2013 | 6 | 155 | NA | NA | None | NA | NA | NA | NA | NA | NA | NA | None |
| MABIPA | MABI | NA | 2013-07-09 | 2421 | 2013 | 7 | 190 | NA | NA | None | NA | NA | NA | NA | NA | NA | NA | None |
| MABISA | MABI | NA | 2013-05-06 | 2136 | 2013 | 5 | 126 | Clear | Colorless | None | None | NA | NA | None | NA | None | NA | None |
| MABISA | MABI | NA | 2013-06-04 | 2135 | 2013 | 6 | 155 | Clear | Colorless | None | None | NA | NA | None | NA | None | NA | None |
| MABISA | MABI | NA | 2013-07-09 | 2139 | 2013 | 7 | 190 | Clear | Colorless | None | None | Light Coating | Green | None | Green | None | NA | None |
Get observations for all streams in ACAD May 2023
ACAD_streams <- getStreamObs(park = 'ACAD', years = 2023, months = 5)
print_head(ACAD_streams)# top 6 rows
| SiteCode | UnitCode | SubUnitCode | EventDate | EventCode | year | month | doy | WaterClarity | WaterColor | WaterCondition | AlgaeSlimeExtent | AlgaeSlimeAmount | AlgaeSlimeColor | AlgaeFilExtent | AlgaeFilColor | AlgaeClumpsExtent | AlgaeClumpsColor | Algae_Notes |
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| ACBRWN | ACAD | NA | 2023-05-08 | 4669 | 2023 | 5 | 128 | Clear | Colorless | None | None | NA | NA | None | NA | None | NA | None |
| ACCADS | ACAD | NA | 2023-05-05 | 4666 | 2023 | 5 | 125 | Clear | Colorless | None | None | NA | NA | None | NA | None | NA | None |
| ACDKLI | ACAD | NA | 2023-05-04 | 4664 | 2023 | 5 | 124 | Clear | Colorless | Foamy | None | NA | NA | None | NA | None | NA | None |
| ACDUCK | ACAD | NA | 2023-05-09 | 4670 | 2023 | 5 | 129 | Clear | Colorless | None | Occasional | Light Coating | Green | None | NA | None | NA | None |
| ACHADB | ACAD | NA | 2023-05-05 | 4667 | 2023 | 5 | 125 | Clear | Colorless | None | None | NA | NA | None | NA | None | NA | None |
| ACLKWO | ACAD | NA | 2023-05-03 | 4663 | 2023 | 5 | 123 | Clear | Colorless | None | None | NA | NA | None | NA | None | NA | None |
Get the long versions of stream observations in LNETN parks from May to October
lnetn <- c("MABI", "MIMA", "MORR", "ROVA", "SAGA", "SAIR", "SARA", "WEFA")
lnetn_obs <- getStreamObs(park = lnetn, months = 5:10, output = "verbose")
print_head(lnetn_obs)# top 6 rows
| GroupCode | GroupName | UnitCode | UnitName | SubUnitCode | SubUnitName | SiteCode | SiteName | SiteType | Project | EventDate | EventCode | WaterClarity | WaterColor | WaterCondition | AlgaeSlimeExtent | AlgaeSlimeAmount | AlgaeSlimeColor | AlgaeFilExtent | AlgaeFilColor | AlgaeClumpsExtent | AlgaeClumpsColor | Algae_Notes | IsEventCUI | year | month | doy |
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| NETN | Northeast Temperate Network | MABI | Marsh-Billings-Rockefeller National Historical Park | NA | NA | MABIPA | The Pogue | Lake | NETN_LS | 2013-05-06 | 2424 | NA | NA | None | NA | NA | NA | NA | NA | NA | NA | None | FALSE | 2013 | 5 | 126 |
| NETN | Northeast Temperate Network | MABI | Marsh-Billings-Rockefeller National Historical Park | NA | NA | MABIPA | The Pogue | Lake | NETN_LS | 2013-06-04 | 2423 | NA | NA | None | NA | NA | NA | NA | NA | NA | NA | None | FALSE | 2013 | 6 | 155 |
| NETN | Northeast Temperate Network | MABI | Marsh-Billings-Rockefeller National Historical Park | NA | NA | MABIPA | The Pogue | Lake | NETN_LS | 2013-07-09 | 2421 | NA | NA | None | NA | NA | NA | NA | NA | NA | NA | None | FALSE | 2013 | 7 | 190 |
| NETN | Northeast Temperate Network | MABI | Marsh-Billings-Rockefeller National Historical Park | NA | NA | MABISA | Pogue Brook | Stream | NETN_LS | 2013-05-06 | 2136 | Clear | Colorless | None | None | NA | NA | None | NA | None | NA | None | FALSE | 2013 | 5 | 126 |
| NETN | Northeast Temperate Network | MABI | Marsh-Billings-Rockefeller National Historical Park | NA | NA | MABISA | Pogue Brook | Stream | NETN_LS | 2013-06-04 | 2135 | Clear | Colorless | None | None | NA | NA | None | NA | None | NA | None | FALSE | 2013 | 6 | 155 |
| NETN | Northeast Temperate Network | MABI | Marsh-Billings-Rockefeller National Historical Park | NA | NA | MABISA | Pogue Brook | Stream | NETN_LS | 2013-07-09 | 2139 | Clear | Colorless | None | None | Light Coating | Green | None | Green | None | NA | None | FALSE | 2013 | 7 | 190 |
This function joins stage and water level data, and allows you to query by park, site, site_type, year, and month. Note that WL data start in 2013 in the view.
Get water level data for Bubble Pond.
bubl <- getWaterLevel(site = "ACBUBL", years = 2013:2023)
print_head(bubl)# top 6 rows
| SiteCode | SiteName | UnitCode | SubUnitCode | EventDate | EventCode | year | month | doy | DatumName | DatumType | DatumFunction | Active | TU.TD | StageMethod | DatumLatitude | DatumLongitude | DatumElevation_ft | DatumElevationFeet | GageReadingFeet | WaterLevel_Feet | WaterLevel_m |
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| ACBUBL | Bubble Pond | ACAD | NA | 2013-05-31 | 2128 | 2013 | 5 | 151 | SD1 | Drilled hole | Stage Measurement | TRUE | TD | Ruler | 44.34948 | -68.24053 | 333.39 | 333.39 | -0.49 | 332.90 | 101.4679 |
| ACBUBL | Bubble Pond | ACAD | NA | 2013-06-24 | 2129 | 2013 | 6 | 175 | SD1 | Drilled hole | Stage Measurement | TRUE | TD | Ruler | 44.34948 | -68.24053 | 333.39 | 333.39 | -0.77 | 332.62 | 101.3826 |
| ACBUBL | Bubble Pond | ACAD | NA | 2013-07-18 | 2130 | 2013 | 7 | 199 | SD1 | Drilled hole | Stage Measurement | TRUE | TD | Ruler | 44.34948 | -68.24053 | 333.39 | 333.39 | -0.96 | 332.43 | 101.3247 |
| ACBUBL | Bubble Pond | ACAD | NA | 2013-08-28 | 2370 | 2013 | 8 | 240 | SD1 | Drilled hole | Stage Measurement | TRUE | TD | Ruler | 44.34948 | -68.24053 | 333.39 | 333.39 | -0.96 | 332.43 | 101.3247 |
| ACBUBL | Bubble Pond | ACAD | NA | 2013-09-19 | 2389 | 2013 | 9 | 262 | SD1 | Drilled hole | Stage Measurement | TRUE | TD | Ruler | 44.34948 | -68.24053 | 333.39 | 333.39 | -0.78 | 332.61 | 101.3795 |
| ACBUBL | Bubble Pond | ACAD | NA | 2013-10-24 | 2410 | 2013 | 10 | 297 | SD1 | Drilled hole | Stage Measurement | TRUE | TD | Ruler | 44.34948 | -68.24053 | 333.39 | 333.39 | -0.78 | 332.61 | 101.3795 |
Get water level data for Weir Pond in August.
weir <- getWaterLevel(site = "WEFAPA", months = 8)
print_head(weir)# top 6 rows
| SiteCode | SiteName | UnitCode | SubUnitCode | EventDate | EventCode | year | month | doy | DatumName | DatumType | DatumFunction | Active | TU.TD | StageMethod | DatumLatitude | DatumLongitude | DatumElevation_ft | DatumElevationFeet | GageReadingFeet | WaterLevel_Feet | WaterLevel_m |
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| WEFAPA | Weir Pond | WEFA | NA | 2013-08-28 | 2226 | 2013 | 8 | 240 | SD1 | Bolt | Stage Measurement | TRUE | TD | Ruler | 41.26022 | -73.45142 | 569 | 569 | -0.80 | 568.20 | 173.1874 |
| WEFAPA | Weir Pond | WEFA | NA | 2014-08-12 | 2668 | 2014 | 8 | 224 | SD1 | Bolt | Stage Measurement | TRUE | TD | Ruler | 41.26022 | -73.45142 | 569 | 569 | -0.96 | 568.04 | 173.1386 |
| WEFAPA | Weir Pond | WEFA | NA | 2015-08-20 | 2827 | 2015 | 8 | 232 | SD1 | Bolt | Stage Measurement | TRUE | TD | Ruler | 41.26022 | -73.45142 | 569 | 569 | -1.19 | 567.81 | 173.0685 |
| WEFAPA | Weir Pond | WEFA | NA | 2016-08-25 | 3161 | 2016 | 8 | 238 | SD1 | Bolt | Stage Measurement | TRUE | TD | Ruler | 41.26022 | -73.45142 | 569 | 569 | -1.05 | 567.95 | 173.1112 |
| WEFAPA | Weir Pond | WEFA | NA | 2017-08-24 | 3403 | 2017 | 8 | 236 | SD1 | Bolt | Stage Measurement | TRUE | TD | Ruler | 41.26022 | -73.45142 | 569 | 569 | -1.20 | 567.80 | 173.0654 |
| WEFAPA | Weir Pond | WEFA | NA | 2018-08-14 | 3664 | 2018 | 8 | 226 | SD1 | Bolt | Stage Measurement | TRUE | TD | Ruler | 41.26022 | -73.45142 | 569 | 569 | -0.51 | 568.49 | 173.2758 |
Get water level data for ACAD lakes in July 2023.
acad_jul <- getWaterLevel(park = "ACAD", years = 2023, months = 7)
print_head(acad_jul)
| SiteCode | SiteName | UnitCode | SubUnitCode | EventDate | EventCode | year | month | doy | DatumName | DatumType | DatumFunction | Active | TU.TD | StageMethod | DatumLatitude | DatumLongitude | DatumElevation_ft | DatumElevationFeet | GageReadingFeet | WaterLevel_Feet | WaterLevel_m |
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| ACBRWN | Browns Brook | ACAD | NA | 2023-07-05 | 4747 | 2023 | 7 | 186 | SD1 | Bolt | Stage Measurement | TRUE | TD | Ruler | 44.33926 | -68.30148 | 46.73 | 46.729 | -0.37 | 46.359 | 14.13022 |
| ACBRWN | Browns Brook | ACAD | NA | 2023-07-05 | 4747 | 2023 | 7 | 186 | SD1 | Bolt | Stage Measurement | TRUE | TD | Ruler | 44.33926 | -68.30148 | 46.73 | 46.729 | -0.38 | 46.349 | 14.12718 |
| ACBUBL | Bubble Pond | ACAD | NA | 2023-07-17 | 4734 | 2023 | 7 | 198 | SD2 | Bolt | Stage Measurement | TRUE | TU | Ruler | NA | NA | 332.00 | 332.000 | 1.70 | 333.700 | 101.71176 |
| ACCADS | Cadillac Stream | ACAD | NA | 2023-07-11 | 4754 | 2023 | 7 | 192 | RP2 | Bolt | Stage Measurement | TRUE | TU | Ruler | 44.34490 | -68.21690 | 418.05 | 418.050 | 0.30 | 418.350 | 127.51308 |
| ACCADS | Cadillac Stream | ACAD | NA | 2023-07-11 | 4754 | 2023 | 7 | 192 | RP2 | Bolt | Stage Measurement | TRUE | TU | Ruler | 44.34490 | -68.21690 | 418.05 | 418.050 | 0.30 | 418.350 | 127.51308 |
| ACCADS | Cadillac Stream | ACAD | NA | 2023-07-11 | 4754 | 2023 | 7 | 192 | RP3 | Bolt | Stage Measurement | TRUE | TU | Ruler | 44.34490 | -68.21690 | 417.96 | 417.961 | 0.39 | 418.351 | 127.51338 |
This function produces a plot that summarizes the range of historic data compared with current measurements. The function can handle chemistry, Sonde in situ, Secchi depth, Light Penetration, and Discharge data, although it functions best with sonde and chemistry data. Historic measurements are displayed as the min-max values ever previously recorded (outermost band), upper and lower 95% distribution and middle 50% distribution (inner quartiles) of values previously recorded (inner bands). The line represents the median value.
Currently you can only specify one parameter at a time. Values that
exceed water quality thresholds (where they exist) are plotted as orange
and will show an orange point in the legend. Values within WQ thresholds
or for parameters without set thresholds are black. You can include
threshold lines (default), or remove them, where they make the y axis
range too big, via threshold = FALSE. If multiple sites are
specified, they will be faceted.
You can now add gridlines to the plot via the gridlines argument, and Temp in F via “Temp_F” argument.
Plot pH in Jordan Pond for 2023 with gridlines on the y-axis
pjord_ph <-
plotWaterBands(site = "ACJORD", year_curr = 2023, years_historic = 2006:2022,
parameter = "pH", legend_position = 'right', gridlines = 'grid_y')
pjord_ph
Plot TN in Jordan Pond for 2023, including censored and gridlines on both x and y axes
pjord_tn <-
plotWaterBands(site = "ACJORD", year_curr = 2023, years_historic = 2006:2022,
parameter = "TN_mgL", legend_position = 'right', include_censored = T, gridlines = "both")
pjord_tn
Same as above, but drop threshold lines and add gridlines on x-axis
pjord_tn2 <-
plotWaterBands(site = "ACJORD", year_curr = 2023, years_historic = 2006:2022,
parameter = "TN_mgL", legend_position = 'right', include_censored = T, threshold = F, gridlines = "grid_x")
pjord_tn2
Plot TN in Kroma Kill in SARA in 2023, with no gridlines (Default)
kroma <-
plotWaterBands(site = "SARASA", year_curr = 2023, years_historic = 2006:2022, parameter = "TN",
legend_position = 'right')
kroma
This function produces points or loess smoothed lines of 2 variables, filtered on park, site, year, month, and 2 parameters. Works with lab chemistry, Sonde in situ, discharge, secchi depth, water level, and light penetration ratio. If multiple sites are specified, they will be plotted on the same figure, unless facet_site = T. Note that if you specify a site and parameter combination that doesn’t exist (e.g., a stream site and a parameter only collected in lakes), the function will return an error message instead of an empty plot. Censored values are not permitted in this function.
Plot Temp vs DO for ROVA all years on same figure
rova_scat <-
plotScatterPlot(park = "ROVA", parameters = c("DO_mgL", "Temp_C"),
palette = 'viridis', facet_site = F, legend_position = "bottom")
rova_scat
Plot Secchi depth vs. surface DOC in Eagle Lake, Jordan Pond, Echo Lake, and Witch Hole Pond
secchi_doc <-
plotScatterPlot(site = c("ACEAGL", "ACJORD", "ACWHOL", "ACECHO"),
parameters = c("SDepth_m", "DOC_mgL"),
span = 0.9, facet_site = F, legend_position = 'bottom',
palette = c("red", "orange", "purple4", "blue"))
secchi_doc
Same as above, but points only
plotScatterPlot(site = c("ACEAGL", "ACJORD", "ACWHOL", "ACECHO"),
parameters = c("SDepth_m", "DOC_mgL"),
span = 0.9, facet_site = F, legend_position = 'bottom',
layers = 'points')
Plot smoothed discharge vs. specific conductance for the Pogue Brook using span of 0.9, and green symbols.
mabi_dsc <-
plotScatterPlot(site = "MABISA", parameters = c("SpCond_uScm", "Discharge_cfs"),
span = 0.9, palette = c("forestgreen"))
mabi_dsc
Plot smoothed discharge vs. specific conductance for SARA streams using span of 0.9.
sara_scd <-
plotScatterPlot(park = "SARA", parameters = c("SpCond_uScm", "Discharge_cfs"),
span = 0.9, facet_site = F, legend_position = 'bottom',
palette = c("blue", "orange"))
sara_scd
Same as above, but faceted by site.
plotScatterPlot(park = "SARA", parameters = c("SpCond_uScm", "Discharge_cfs"),
span = 0.9, facet_site = T)
Plot TN vs discharge in SARA streams
sara_tnd <-
plotScatterPlot(park = "SARA", parameters = c("TN_mgL", "Discharge_cfs"),
span = 0.9, facet_site = F)
sara_tnd
This function produces a trend plot filtered on park, site, year, month, and parameter. It works with chemistry, Sonde in situ, Secchi depth, Light Penetration, and Discharge data. If multiple sites are specified, they will be plotted on the same figure. If multiple parameters are specified, they will be plotted on separate figures. If smooth = T, a loess smoothed line will connect through the data. If smooth = F and layers includes “lines”, then lines will connect the sample points, but will not connect across years, because of the break between October and May.
There are several arguments to customize plots.active.
layers argument.
smooth.
threshold. Upper limits are dashed. Lower limits are
dotted.
sample_depth.
include_censored.
palette. Default is ‘viridis’, but
other options are magma (yellow, red, purple), plasma (brighter version
of magma), turbo (rainbow), or specify a vector of colors manually. See
the
intro
do viridis site for more info on built in color palettes.
legend_position. If you don’t
want to show the legend, legend_position = 'none'.
parameter = "Temp_F".
?plotTrend()
Plot non-smoothed surface pH for Eagle Lake for all years with gridlines on y-axis.
eag_ph <-
plotTrend(site = "ACEAGL", parameter = "pH", palette = 'mako', years = 2021:2023) + theme_WQ()
eag_ph
Plot smoothed surface pH for Eagle Lake for past 3 years using default span of 0.3 and by default not including the legend.
plotTrend(site = "ACEAGL", parameter = "pH", palette = 'dimgrey', years = 2021:2023)
Plot smoothed surface pH for Eagle Lake and Jordan Pond for all years, with turbo palette, and using span of 0.75.
eag_jord <-
plotTrend(site = c("ACEAGL", "ACJORD"), parameter = "pH", span = 0.75,
palette = "turbo", legend_position = 'bottom')
eag_jord
Plot smoothed Secchi Depth in Jordan Pond for all years, including the legend, different color palette, and using span of 0.75.
jord_sec <-
plotTrend(site = "ACJORD", parameter = "SDepth_m", span = 0.75, palette = 'mako')
jord_sec
Plot unsmoothed SO4 in Witch Hole Pond for all years, including censored values.
whol_so4 <-
plotTrend(site = "ACWHOL", parameter = "SO4_ueqL",
smooth = F, include_censored = TRUE, legend_position = 'bottom')
whol_so4
Plot unsmoothed line only for pH in Witch Hole Pond for all years.
whol_ph <-
plotTrend(site = "ACWHOL", parameter = "pH", layers = "lines",
smooth = F, legend_position = 'none')
whol_ph
Plot smoothed surface pH for active SARA streams over all years with 0.6 span.
p <- plotTrend(park = "SARA", site = c("SARASA", "SARASC", "SARASD"),
site_type = "stream", parameter = "pH",
legend_position = "right", span = 0.6)
p
Plot smoothed surface Specific Conductance for all MIMA streams over all years with 0.6 span.
mima_sc <-
plotTrend(park = "MIMA", site_type = "stream",
parameter = "SpCond_uScm", legend_position = "right", span = 0.6,
palette = c("blue", "orange", "green3"))
mima_sc
Plot non-smoothed surface of multiple Sonde parameters for all MIMA streams over all years with 0.6 span. Note that here I used Temp_F.
params <- c("Temp_F", "SpCond_uScm", "DOsat_pct", "pH")
mima_sonde <-
plotTrend(park = "MIMA", site_type = "stream",
parameter = params, legend_position = "right", span = 0.6)
mima_sonde
Plot smoothed surface Secchi Depth, Specific Conductance, pH, and DOC in Jordan Pond for all years, including the legend, different color palette, and using span of 0.75.
jord4 <-
plotTrend(site = "ACJORD", parameter = c("SDepth_m", "SpCond_uScm", "pH", "DOC_mgL"),
span = 0.75, palette = 'mako')
jord4
Plot smoothed surface water depth in the Pogue for all years, including a different color palette, and using span of 0.75.
pogue_wl <-
plotTrend(site = "MABIPA", parameter = "WaterLevel_Feet", span = 0.75,
palette = 'mako')
pogue_wl
Plot smoothed TN, TP and SO4 in all MORR sites for all years, including the legend, different color palette, and using span of 0.6. Thresholds, where they exist, plot by default.
morr <-
plotTrend(park = "MORR", parameter = c("TN_mgL", "TP_ugL", "SO4_ueqL"),
span = 0.6, legend_position = 'bottom', palette = 'plasma')
morr
This function produces a heatmap in 1-m bins for ACAD and 0.25m bins for LNETN. You can filter on park, site, year, month, Sonde in situ parameter and either sample relative to the surface or relative to surface elevation. You can only specify one parameter at a time. If multiple sites or years are selected, plots will be faceted on those factors. Keep options limited for best plotting. Note also that you can either select ACAD or LNETN parks, because of the differences in binning.
The option to plot relative to surface elevation (eg depth_type = ‘elev’) corrects sample depth for elevation using water level data and datum elevation for that sampling event. The elevation-corrected option allows you to see how the water column is shifting over time, but currently only works for years >= 2013 in ACAD, as water levels prior to that are not in the current data package. Default setting is raw, where the raw sample depths are plotted instead of elevation.
Note that occasionally profiles skip a bin, which show up as white sections in the plots. Incomplete sampling in 2020 and 2021 also shows up as white sections. If you specify a lake x year x parameter combination that doesn’t exist (e.g., a year a lake isn’t sampled), the function will return an error message instead of an empty plot.
The width of the profiles take into account the number of days between sampling events. For the first and last months (typically May and October), the left/right side of the profiles are padded by 14 days. Otherwise, profile widths are centered on the sample day with the left side representing half the number of days between that visit and the previous visit and the right side representing half the number of days between that visit and the following visit. Black lines are the thermocline, as calculated by rLakeAnalyzer.
There are several arguments to customize plots.plot_thermocline = TRUE (default). The thermocline is
calculated by rLakeAnalyzer, and is the depth/elevation at which the
largest change in temperature occurs in the sampled water column. If no
thermocline is detected, as defined by
rLakeAnalyzer::thermo.depth(), nothing is plotted.
active.
legend_position. If you don’t
want to show the legend, legend_position = 'none'.
parameter = "Temp_F".
RColorBrewer::display.brewer.all(type = 'div')
RColorBrewer::display.brewer.all(type = 'seq')
Plot temperature (in F) for Upper Hadlock for years 2013 - 2023 corrected by elevation with thermocline plotted as black lines, with gridlines on y.
uhad_f <-
plotLakeProfile(site = "ACUHAD", parameter = "Temp_F", depth_type = 'elev',
years = 2013:2023, gridlines = "grid_y")
uhad_f
Plot temp (in C) using raw sample depth (default) for all LNETN lakes sampled in 2023.
lnetn_c <-
plotLakeProfile(park = "LNETN", parameter = "Temp_C", years = 2023, palette = "Spectral")
lnetn_c
Plot temperature for Eagle Lake for years 2006 - 2023 with raw sample depth. Note that we can go back to 2006 because we’re using raw sample depth instead of elevation.
eag_c <-
plotLakeProfile(site = "ACEAGL", parameter = "Temp_C", depth_type = 'raw',
years = 2006:2023)
eag_c
Same plot as above, but with no plot title or thermocline.
plotLakeProfile(site = "ACEAGL", parameter = "Temp_C", depth_type = 'raw',
years = 2006:2023, plot_title = FALSE, plot_thermocline = F)
Plot temperature for all ACAD lakes sampled in 2023 and raw sample depth.
lakes23 <- c("ACBUBL", "ACEAGL", "ACECHO", "ACJORD", "ACLONG", "ACROUN",
"ACSEAL", "ACUBRK", "ACUHAD", "ACWHOL")
plot_23C <-
plotLakeProfile(park = "ACAD", site = lakes23, parameter = "Temp_C",
depth_type = 'raw', years = 2023)
plot_23C
Plot DO all ACAD lakes sampled in 2023 and raw sample depth, using reversed RdYlBu palette. Temperature thermocline is also included as black lines.
plot_23do <-
plotLakeProfile(park = "ACAD", site = lakes23,
parameter = "DOsat_pct", depth_type = 'raw', years = 2023,
palette = 'RdYlBu', color_rev = TRUE)
plot_23do
Plot specific conductance for Seal Cove Pond from 2013 to 2023 and sample elevation. Uses spectral palette by default and adds site name as title by default. Thermocline is also plotted as default.
scove_sc <-
plotLakeProfile(site = "ACSEAL", parameter = "SpCond_uScm",
depth_type = 'elev', years = 2013:2023)
scove_sc
Plot pH for Jordan Pond from 2013 to 2023 and sample elevation, using reversed spectral palette.
jord_ph <-
plotLakeProfile(site = "ACJORD", parameter = "pH",
depth_type = 'elev', years = 2013:2023,
color_rev = TRUE)
jord_ph
Plot pH for all ACAD lakes sampled in 2022 and 2023 and raw sample depth, using reversed RdYlBu palette.
p223 <-
plotLakeProfile(park = "ACAD", site = c("ACBUBL", "ACEAGL", "ACECHO", "ACJORD", "ACLONG", "ACSEAL",
"ACUHAD", "ACWHOL"),
parameter = "pH", depth_type = 'raw', years = 2022:2023,
palette = 'RdYlBu', color_rev = TRUE)
p223
Combine plots for temp, DO, pH, and conductance in Bubble Pond for 2023
using the cowplot package.
To minimize typing, I define the parameters I wanted at the beginning. This allows you to adjust the parameters once (i.e., change site), and run through the rest of the code without having to edit it. I also only included the plot title on the first figure, and turned it off for the rest.
The cowplot package must be installed to use this code.
Install the package via install.packages('cowplot'). There
are other packages to combine plots, including grid and
gridExtra, and the function ggarrage() in
ggpubr. I tend to start with cowplot, because it’s easy to
use and has a great help
page. If I really need to customize a plot (like custom spacing for
each plot), then I use grid/gridExtra, which allows for
more customization, but is a bit harder to work with.
library(cowplot)
sitecode = "ACBUBL"
sitename = getSites(site = sitecode)$SiteName
year = 2023
mon = 5:10
depth = 'elev'
ptitle = F
tplot <- plotLakeProfile(site = sitecode, parameter = "Temp_C", depth_type = depth,
years = year, months = mon, plot_title = ptitle)
doplot <- plotLakeProfile(site = sitecode, parameter = "DOsat_pct", depth_type = depth,
years = year, months = mon, color_rev = T, plot_title = ptitle)
pHplot <- plotLakeProfile(site = sitecode, parameter = "pH", depth_type = depth,
years = year, months = mon, palette = "RdYlBu", color_rev = T,
plot_title = ptitle)
cnplot <- plotLakeProfile(site = sitecode, parameter = "SpCond_uScm", depth_type = depth,
years = year, months = mon, palette = 'RdBu',
plot_title = ptitle)
# Default settings
plot_grid(tplot, doplot, pHplot, cnplot)
Same plot as above, but customize plot widths, so DO and SpCond have more space for legend, and add title above the grid.
In this case, we’re creating the plot grid with relative widths for each plot. Then we’re combining the title and the plot grid in another grid, setting the title height to be much smaller than the plot grid.
Note that sitename and year are defined in code chunk above.
title <- ggdraw() + draw_label(paste0(sitename, " (", year, ")"), size = 11, fontface = 'bold',
x = 0.05, hjust = 0, vjust = 0)
pgrid <- plot_grid(tplot, doplot, pHplot, cnplot, rel_widths = c(0.9, 0.95, 0.85, 1)) # doesn't seem to be working
plot_grid(title, pgrid, ncol = 1, rel_heights = c(0.1, 1))
This function produces a plot with dual y-axes, one for precipitation and one for discharge. The x-axis is date. This function only works for one stream monitoring site at a time. Note that ggplot tends to have a lot of warnings that are hard to suppress, particularly for this plot, which has a daily value for precipitation and only monthly values for discharge. You’re always going to get a message about that by using this function. Function currently only plots years where discharge is collected. Discharge is plotted as points and not lines, because discharge can change a lot between sampling events.
Note that the climateNETN package must be
installed for this function to work, as it relies on downloading daily
precipitation data. To install run
pak::pkg_install("doi-nps/climateNETN")
Plot Discharge for Mill Brook in MIMA for past 3 years using default colors and gridlines on the y-axis and english units.
mima_disch <-
plotPrecipDischarge(site = c("MIMASA"), years = 2021:2023, gridlines = "grid_y", units = "eng")
mima_disch
Plot daily precipitation vs discharge for all ROVA sites in 2021, only accepting observations of”Excellent”, “Good”, or “Fair”.
rova_disch <-
plotPrecipDischarge(park = "ROVA", years = 2021, rating = c("E", "G", "F"))
rova_disch
Plot Discharge for Aunt Betty Inlet and Kebo Stream for 2024 using different colors. Note that this can be slow because has to download precip. data from NADP. LNETN parks download from a faster web service.
bin_keb <-
plotPrecipDischarge(site = c("ACABIN", "ACKEBO"), years = 2024, palette = c("cornflowerblue", "orange"))
bin_keb
Summarize number of samples collected per park, site, month, and parameter. Resulting data frame show number of samples collected for each month, and whether the value is real (month) or censored (month_cens).
Summarize all events for ACAD for all years and active sites
acad_ev <- sumEvents(park = "ACAD")
print_head(acad_ev)
| UnitCode | SiteType | SiteName | param_type | Parameter | year_range | num_years | May | Jun | Jul | Aug | Sep | Oct | May_cens | Jun_cens | Jul_cens | Aug_cens | Sep_cens | Oct_cens |
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| ACAD | Lake | Aunt Bettys Pond | Lab chemistry | ANC_ueqL | 2006 – 2024 | 7 | 0 | 4 | 0 | 4 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 |
| ACAD | Lake | Aunt Bettys Pond | Lab chemistry | ChlA_ugL | 2006 – 2024 | 7 | 3 | 7 | 3 | 7 | 3 | 3 | 0 | 0 | 0 | 0 | 0 | 0 |
| ACAD | Lake | Aunt Bettys Pond | Lab chemistry | DOC_mgL | 2006 – 2024 | 7 | 3 | 5 | 3 | 5 | 3 | 3 | 0 | 0 | 0 | 0 | 0 | 0 |
| ACAD | Lake | Aunt Bettys Pond | Lab chemistry | TN_mgL | 2006 – 2024 | 7 | 3 | 7 | 3 | 7 | 3 | 3 | 0 | 0 | 0 | 0 | 0 | 0 |
| ACAD | Lake | Aunt Bettys Pond | Lab chemistry | TP_ugL | 2006 – 2024 | 7 | 3 | 7 | 3 | 7 | 3 | 3 | 0 | 0 | 0 | 0 | 0 | 0 |
| ACAD | Lake | Aunt Bettys Pond | Light penetration | PenetrationRatio | 2006 – 2024 | 7 | 27 | 38 | 34 | 31 | 35 | 35 | 0 | 0 | 0 | 0 | 0 | 0 |
Summarize only lake events for ACAD for all years
acad_lk <- sumEvents(park = "ACAD", site_type = "lake")
print_head(acad_lk)
| UnitCode | SiteType | SiteName | param_type | Parameter | year_range | num_years | May | Jun | Jul | Aug | Sep | Oct | May_cens | Jun_cens | Jul_cens | Aug_cens | Sep_cens | Oct_cens |
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| ACAD | Lake | Aunt Bettys Pond | Lab chemistry | ANC_ueqL | 2006 – 2024 | 7 | 0 | 4 | 0 | 4 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 |
| ACAD | Lake | Aunt Bettys Pond | Lab chemistry | ChlA_ugL | 2006 – 2024 | 7 | 3 | 7 | 3 | 7 | 3 | 3 | 0 | 0 | 0 | 0 | 0 | 0 |
| ACAD | Lake | Aunt Bettys Pond | Lab chemistry | DOC_mgL | 2006 – 2024 | 7 | 3 | 5 | 3 | 5 | 3 | 3 | 0 | 0 | 0 | 0 | 0 | 0 |
| ACAD | Lake | Aunt Bettys Pond | Lab chemistry | TN_mgL | 2006 – 2024 | 7 | 3 | 7 | 3 | 7 | 3 | 3 | 0 | 0 | 0 | 0 | 0 | 0 |
| ACAD | Lake | Aunt Bettys Pond | Lab chemistry | TP_ugL | 2006 – 2024 | 7 | 3 | 7 | 3 | 7 | 3 | 3 | 0 | 0 | 0 | 0 | 0 | 0 |
| ACAD | Lake | Aunt Bettys Pond | Light penetration | PenetrationRatio | 2006 – 2024 | 7 | 27 | 38 | 34 | 31 | 35 | 35 | 0 | 0 | 0 | 0 | 0 | 0 |
Summarize LNETN events only
lnetn <- sumEvents(park = "LNETN")
print_head(lnetn)
| UnitCode | SiteType | SiteName | param_type | Parameter | year_range | num_years | May | Jun | Jul | Aug | Sep | Oct | May_cens | Jun_cens | Jul_cens | Aug_cens | Sep_cens | Oct_cens |
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| MABI | Lake | The Pogue | Lab chemistry | ANC_ueqL | 2006 – 2024 | 18 | 0 | 12 | 0 | 12 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 |
| MABI | Lake | The Pogue | Lab chemistry | TN_mgL | 2006 – 2024 | 18 | 6 | 18 | 6 | 18 | 6 | 6 | 0 | 0 | 0 | 0 | 0 | 0 |
| MABI | Lake | The Pogue | Lab chemistry | TP_ugL | 2006 – 2024 | 18 | 6 | 18 | 6 | 18 | 6 | 6 | 0 | 0 | 0 | 0 | 0 | 0 |
| MABI | Lake | The Pogue | Light penetration | PenetrationRatio | 2006 – 2024 | 18 | 120 | 137 | 130 | 134 | 122 | 120 | 0 | 0 | 0 | 0 | 0 | 0 |
| MABI | Lake | The Pogue | Sonde field meas. | DO_mgL | 2006 – 2024 | 18 | 16 | 18 | 17 | 18 | 17 | 19 | 0 | 0 | 0 | 0 | 0 | 0 |
| MABI | Lake | The Pogue | Sonde field meas. | SpCond_uScm | 2006 – 2024 | 18 | 16 | 18 | 17 | 18 | 17 | 19 | 0 | 0 | 0 | 0 | 0 | 0 |