GeoTox {GeoTox} | R Documentation |
GeoTox S3 object
Description
An S3 object that can be used to help organize the data and results of a GeoTox analysis.
Usage
GeoTox()
## S3 method for class 'GeoTox'
plot(x, type = c("resp", "hill", "exposure", "sensitivity"), ...)
Arguments
x |
GeoTox object. |
type |
type of plot. |
... |
arguments passed to subsequent methods. |
Value
a GeoTox S3 object
See Also
plot_resp, plot_hill, plot_exposure, plot_sensitivity
Examples
# Use a subset of the package data for demonstration purposes
set.seed(2357)
n <- 10 # Population size
m <- 5 # Number of regions
idx <- if (m < 100) sample(1:100, m) else 1:100
geoTox <- GeoTox() |>
# Set region and group boundaries (for plotting)
set_boundaries(region = geo_tox_data$boundaries$county,
group = geo_tox_data$boundaries$state) |>
# Simulate populations for each region
simulate_population(age = split(geo_tox_data$age, ~FIPS)[idx],
obesity = geo_tox_data$obesity[idx, ],
exposure = split(geo_tox_data$exposure, ~FIPS)[idx],
simulated_css = geo_tox_data$simulated_css,
n = n) |>
# Estimated Hill parameters
set_hill_params(geo_tox_data$dose_response |>
fit_hill(assay = "endp", chem = "casn") |>
dplyr::filter(!tp.sd.imputed, !logAC50.sd.imputed)) |>
# Calculate response
calculate_response() |>
# Perform sensitivity analysis
sensitivity_analysis()
# Print GeoTox object
geoTox
# Plot hill fits
plot(geoTox, type = "hill")
# Plot exposure data
plot(geoTox, type = "exposure", ncol = 5)
# Plot response data
plot(geoTox)
plot(geoTox, assays = "TOX21_H2AX_HTRF_CHO_Agonist_ratio")
# Plot sensitivity data
plot(geoTox, type = "sensitivity")
plot(geoTox, type = "sensitivity", assay = "TOX21_H2AX_HTRF_CHO_Agonist_ratio")
[Package GeoTox version 0.2.0 Index]