rank_sites_DT {toxEval} | R Documentation |
Rank sites by EAR
Description
The rank_sites_DT
(DT option) and rank_sites
(data frame option) functions
create tables with one row per site. Columns represent the maximum or mean EAR
(depending on the mean_logic argument) for each category ("Chemical Class",
"Chemical", or "Biological") and the frequency of the maximum or mean EAR
exceeding a user specified hit_threshold.
Usage
rank_sites_DT(
chemical_summary,
category = "Biological",
mean_logic = FALSE,
sum_logic = TRUE,
hit_threshold = 0.1
)
rank_sites(
chemical_summary,
category,
hit_threshold = 0.1,
mean_logic = FALSE,
sum_logic = TRUE
)
Arguments
chemical_summary |
Data frame from |
category |
Character. Either "Biological", "Chemical Class", or "Chemical". |
mean_logic |
Logical. |
sum_logic |
Logical. |
hit_threshold |
Numeric threshold defining a "hit". |
Details
The tables show slightly different results for a single site. Rather than multiple columns for categories, there is now 1 row per category (since the site is known).
Value
data frame with one row per site, and the mas or mean EAR and frequency of hits based on the category.
Examples
# This is the example workflow:
path_to_tox <- system.file("extdata", package = "toxEval")
file_name <- "OWC_data_fromSup.xlsx"
full_path <- file.path(path_to_tox, file_name)
tox_list <- create_toxEval(full_path)
ACC <- get_ACC(tox_list$chem_info$CAS)
ACC <- remove_flags(ACC)
cleaned_ep <- clean_endPoint_info(end_point_info)
filtered_ep <- filter_groups(cleaned_ep)
chemical_summary <- get_chemical_summary(tox_list, ACC, filtered_ep)
stats_df <- rank_sites(chemical_summary, "Biological")
rank_sites_DT(chemical_summary, category = "Biological")
rank_sites_DT(chemical_summary, category = "Chemical Class")
rank_sites_DT(chemical_summary, category = "Chemical")