Learn R Programming

webchem (version 0.5.0)

get_etoxid: Get ETOX ID

Description

Query ETOX: Information System Ecotoxicology and Environmental Quality Targets https://webetox.uba.de/webETOX/index.do for their substance ID

Usage

get_etoxid(
  query,
  match = c("best", "all", "first", "ask", "na"),
  verbose = TRUE
)

Arguments

query

character; The searchterm

match

character; How should multiple hits be handeled? "all" returns all matched IDs, "first" only the first match, "best" the best matching (by name) ID, "ask" is a interactive mode and the user is asked for input, "na" returns NA if multiple hits are found.

verbose

logical; print message during processing to console?

Value

a dataframe with 4 columns: etoxID, matched substance, string distance to match and the queried string

See Also

etox_basic for basic information, etox_targets for quality targets and etox_tests for test results.

Examples

Run this code
# NOT RUN {
# might fail if API is not available
get_etoxid("Triclosan")
# multiple inputs
comps <- c("Triclosan", "Glyphosate")
get_etoxid(comps)
get_etoxid(comps, match = "all")
# }

Run the code above in your browser using DataLab