plot_ecxsys {stressaddition}R Documentation

Plot the results of the ECx-SyS model

Description

Plot the observed and modeled survivals and stresses.

Usage

plot_stress(
  model,
  which = c("sys_tox", "sys_tox_observed", "sys_tox_env", "sys_tox_env_observed"),
  show_legend = FALSE,
  xlab = "concentration",
  ylab = "stress",
  main = NULL
)

plot_survival(
  model,
  which = c("survival_tox", "survival_tox_sys", "survival_tox_observed",
    "survival_tox_env", "survival_tox_env_sys", "survival_tox_env_observed"),
  show_legend = FALSE,
  xlab = "concentration",
  ylab = "survival",
  main = NULL
)

Arguments

model

The model object returned from ecxsys.

which

A vector of curve names to plot. Allowed are all values of names(model$curves) except "concentration". See the Value section of predict_ecxsys for descriptions of these names. Additionally, you can use "survival_tox_observed" and "survival_tox_env_observed" for the observed survival and "sys_tox_observed" and "sys_tox_env_observed" for the observed Sys. Use "all" to plot everything or NA to only draw the axis and labels. Invalid names will be silently ignored.

show_legend

Should the plot include a legend? Defaults to FALSE because it may cover some parts of the plot depending on the plot size and the number of elements shown.

xlab, ylab, main

Axis labels and title.

Value

None

Examples

model <- ecxsys(
    concentration = c(0, 0.05, 0.5, 5, 30),
    hormesis_concentration = 0.5,
    survival_tox_observed = c(90, 81, 92, 28, 0),
    survival_tox_env_observed = c(29, 27, 33, 5, 0)
)
plot_survival(model, show_legend = TRUE)
plot_stress(model, show_legend = TRUE)

# Plot all curves:
plot_survival(model, which = "all")
plot_stress(model, which = "all")

# Plot only some selected curves:
plot_survival(model, which = c("survival_tox_sys", "survival_tox_env_sys"))
plot_stress(model, which = c("sys_tox", "sys_tox_env"))

# Plot only the observed values:
plot_survival(model, which = c("survival_tox_observed", "survival_tox_env_observed"))
plot_stress(model, which = c("sys_tox_observed", "sys_tox_env_observed"))

[Package stressaddition version 3.1.0 Index]