Skip to contents

Package overview

preMetabolizer preMetabolizer-package
preMetabolizer: Prepare data for stream metabolism modeling

Data access

Download and read meteorological and hydrological data from external sources.

ncei_data()
Get data from the NCEI Data Service API
ncei_datasets()
List available NCEI datasets
ncei_stations()
Search for NCEI weather stations
ncei_bbox()
Compute a bounding box around a point
cdo_datasets() cdo_datacategories() cdo_datatypes() cdo_locationcategories() cdo_locations() cdo_stations() cdo_data()
Query the NCEI Climate Data Online (CDO) Web Services v2 API
cdo_request_count() cdo_reset_request_count()
Inspect and reset the NCEI CDO session request counter
get_noaa_stations()
Get NOAA station information
closest_noaa_stations()
Find NOAA stations near a location
get_ghcnh()
Get GHCNh hourly observations
get_noaa_ghg()
Get NOAA global monthly mean greenhouse gas concentrations
get_nasa_data()
Download NASA POWER hourly data
get_usgs_elev()
Get elevation from the USGS Elevation Point Query Service
iem_networks()
Get Iowa Environmental Mesonet network identifiers
iem_stations() iem_station()
Get Iowa Environmental Mesonet station metadata
iem_current()
Get current Iowa Environmental Mesonet observations
iem_obhistory()
Get one day of Iowa Environmental Mesonet observations
iem_daily()
Get Iowa Environmental Mesonet daily summaries
ks_meso_vars()
Fetch Kansas Mesonet variable metadata
ks_meso_timeseries()
Get Kansas Mesonet time-series data
ks_meso_stations()
Get Kansas Mesonet station information
ks_meso_station_activity()
Get Kansas Mesonet station activity
ks_meso_most_recent()
Get most recent Kansas Mesonet data timestamp
ks_meso_fw13()
Get Kansas Mesonet FW13 data
tex_meso_stations()
Get TexMesonet station information
tex_meso_current()
Get current TexMesonet data
tex_meso_timeseries()
Get recent TexMesonet time-series data
read_shp()
Read a shapefile or zipped shapefile

Chemistry calculations

Calculate dissolved gas concentrations, solubility constants, and related thermodynamic quantities.

calc_O2sat()
Calculate dissolved oxygen saturation
calc_CO2sat()
Calculate dissolved carbon dioxide saturation
calc_CH4sat()
Calculate dissolved methane saturation
calc_N2Osat()
Calculate dissolved nitrous oxide saturation
calc_N2sat()
Calculate dissolved nitrogen saturation
calc_Arsat()
Calculate dissolved argon saturation
calc_CO2_molKg()
Calculate dissolved CO2 concentration in mol/kg
calc_CO2_mgL()
Calculate dissolved CO2 concentration in mg/L
calc_K0()
Calculate the CO2 solubility coefficient
calc_vapor_press()
Saturation vapor pressure of water
xCO2_to_pCO2()
Convert CO2 mole fraction to partial pressure
pCO2_to_xCO2()
Convert CO2 partial pressure to mole fraction

Physical property calculations

Calculate water density, depth from pressure, and solar radiation.

calc_water_density()
Calculate water density
calc_water_height()
Calculate water height from pressure
calc_par()
Calculate modeled photosynthetically active radiation

Statistical utilities

Descriptive statistics and outlier detection for time series data.

calc_bin_width()
Calculate histogram bin width
calc_cv()
Calculate the coefficient of variation
calc_mode()
Calculate the mode of a vector
calc_exceedance_prob()
Calculate flow exceedance probabilities
rcpp_calc_exceedance_prob()
Calculate flow exceedance probabilities with C++
flag_z()
Flag outliers with robust Z-scores

Unit conversion

Convert between common units used in hydrology and atmospheric science.

convert_flow()
Convert stream discharge between units
convert_pressure()
Convert barometric pressure between units
correct_bp()
Correct barometric pressure for elevation change

Time utilities

Work with meteorological seasons and solar time.

get_season()
Determine the astronomical season from a date
even_timesteps()
Fill missing rows in an even time series
convert_to_solar_time() convert_from_solar_time()
Convert a datetime to local solar time

Data

Built-in reference datasets.

french_creek
French Creek stream metabolism data
kings_discharge
Kings Creek daily water data