alternative_products {srppp} | R Documentation |
Find alternative products for all products containing certain active substances
Description
This function searches for uses of a given list of active substances and reports either a table of uses with the number of available alternative products for each use, a detailed table of the alternative product uses, a table of uses without alternatives, or a list containing these three tables.
Usage
alternative_products(
srppp,
active_ingredients,
details = FALSE,
missing = FALSE,
list = FALSE,
lang = c("de", "fr", "it")
)
Arguments
srppp |
A srppp_dm object. |
active_ingredients |
Character vector of active ingredient names that will be matched against the column 'substances_de' in the srppp table 'substances'. |
details |
Should a table of alternative uses with 'wNbr' and 'use_nr' be returned? |
missing |
If this is set to TRUE, uses without alternative product registrations are listed. |
list |
If TRUE, a list of three tables is returned, a table of uses without alternative products ("Lückenindikationen"), a table of the number of alternative products for each use, if any, and a detailed table of all the alternative uses. This argument overrides the arguments 'details' and 'missing'. |
lang |
The language used for the active ingredient names and the returned tables. |
Details
A use is defined here as a combination of an application area, a crop ('culture') and a pathogen ('pest'). This means, that for an alternative product to be found, there has to be an exact match of application area, crop an pathogen.
Value
A tibble::tibble containing use definitions as defined above, i.e. containing columns with the application area, crop and pathogen. Depending on the arguments, columns summarizing or listing the alternative products and/or uses are also contained.
Examples
sr <- srppp_dm()
actives_de <- c("Lambda-Cyhalothrin", "Deltamethrin")
alternative_products(sr, actives_de)
alternative_products(sr, actives_de, missing = TRUE)
alternative_products(sr, actives_de, details = TRUE)
alternative_products(sr, actives_de, list = TRUE)
# Example in Italian
actives_it <- c("Lambda-Cialotrina", "Deltametrina")
alternative_products(sr, actives_it, lang = "it")