download_metab_model: Download metabolism model .RData to local file

View source: R/download_metab_model.R

download_metab_modelR Documentation

Download metabolism model .RData to local file

Description

WARNING: older metab_models may not be compatible with contemporary streamMetabolizer or mda.streams functions. To investigate older models, either apply modernize_metab_model to your downloaded files or use get_metab_model, which does this for you.

Usage

download_metab_model(model_name, folder = tempdir(), version = c("modern",
  "original"), on_remote_missing = c("stop", "return_NA"),
  on_local_exists = c("stop", "skip", "replace"))

Arguments

model_name

the name of the metab_model file

folder

string for a folder location where files should be saved, or a vector of as many folders as there are item_ids

version

character indicating whether you want the original metab_model or a modernized one that works with the current streamMetabolizer version

on_remote_missing

character indicating what to do if the

on_local_exists

character indicating what to do if the folder already contains a file with the intended download name

Value

file handle (character path) for the downloaded file, or NA if the timeseries is unavailable on ScienceBase

Author(s)

Alison P Appling

Examples

## Not run: 
download_metab_model("nwis_04087088-200-150730 0.0.7 MLE_for_PRK_wHarvey_and_sw")

## End(Not run)

USGS-R/mda.streams documentation built on June 3, 2023, 8:43 a.m.