flux {bSi} | R Documentation |
Calculate bSi fluxes based on pbSi (percent bSi) and MARS
Description
Calculate bSi fluxes based on pbSi (percent bSi) and MARS
Usage
flux(pbSi = NULL, MARS = NULL, data_file = NULL, output_csv_file = NULL)
Arguments
pbSi |
Numeric vector of percent biogenic silica. |
MARS |
Numeric vector of sediment mass accumulation rates. |
data_file |
Path to a CSV file containing data with columns 'pbSi' and 'MARS'. |
output_csv_file |
Path to save the calculated flux values as a CSV file. |
Value
A data frame with input values and calculated flux.
Examples
#Example 1: Using vectors
flux_values <- flux(pbSi = c(2, 5, 8), MARS = c(10, 15, 20),
output_csv_file = tempfile("flux_output1.csv"))
#Example 2: Using data from a file
data_file <- system.file("extdata", "example_data.csv", package = "bSi")
flux_values <- flux(data_file = data_file, output_csv_file = tempfile("flux_output2.csv"))
[Package bSi version 1.0.0 Index]