ph.omega: Compute ph correction based on CTD and Bottle data

View source: R/phcorrection.R

ph.omegaR Documentation

Compute ph correction based on CTD and Bottle data

Description

Given CTD and Bottle data, merge the two dataframes together to calculate delta pH and get the corrected pH

Usage

ph.omega(
  ctd,
  bottle,
  flag = 8,
  k1k2 = "l",
  kf = "dg",
  ks = "d",
  pHscale = "T",
  b = "l10"
)

Arguments

ctd

a data frame with AT LEAST the following information with these headings:

season - the season;

agency - the sampling agency;

sampledate - the date of sample collection;

sampletime - the time of sample collection;

station - a code identifying the station;

depth - An integer representing depth in feet;

fieldrep - Field replicate;

labrep - lab replicate;

Latitude - latitude in decimal degrees.;

Longitude - longitude in decimal degrees. Make sure there is a negative sign for the Western coordinates;

temperature - Temperature in Celsius

salinity - the salinity observed at the location in PSU, ideally at time of sampling.

density - density;

ph - ph;

bottle

season - the season;

agency - the sampling agency;

sampledate - the date of sample collection;

sampletime - the time of sample collection;

station - a code identifying the station;

depth - An integer representing depth in feet;

fieldrep - Field replicate;

labrep - lab replicate;

bottle - a number identifying the bottle

lims - not sure;

cruise - not sure;

temperature - Temperature in Celsius

salinity - the salinity observed at the location in PSU, ideally at time of sampling.

ta - alkalinity;

ph - ph;

Details

Get the actual delta pH from the pHinsi function from seacarb Create a linear model to approximate delta ph for the other depths that dont have measurements


SCCWRP/phcorrection documentation built on Jan. 4, 2023, 9:14 p.m.