rot_plot_resistance: rot_plot_resistance plot rotation simulation resistance...

Description Usage Arguments Value Examples

View source: R/rot_plots.r

Description

rot_plot_resistance plot rotation simulation resistance results

Usage

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
rot_plot_resistance(
  df_res2,
  plot_refuge = TRUE,
  mort_thresh = 0.9,
  freq_thresh = 0.5,
  mort_or_freq = "mort",
  logy = TRUE,
  add_gens_under50 = FALSE,
  df_resanother = NULL,
  lwd = 1.5,
  title = "auto",
  plot = TRUE,
  plot_mort = TRUE
)

Arguments

df_res2

dataframe of resistance results from run_rot()

plot_refuge

whether to plot refuge as well as intervention

mort_thresh

mortality threshold for switching insecticides, default 0.9, only used if mort_or_freq is mort

freq_thresh

resistance frequency threshold for switching insecticides, default 0.5, only used if mort_or_freq is freq

mort_or_freq

whether threshold for insecticide change is mortality 'mort' or resistance frequency 'freq'

logy

whether to use log scale for y axis

add_gens_under50

whether to add a label of num generations under 50percent resistance

df_resanother

exploratory option to plot results of another scenario on the same graph

lwd

line thickness for resistance curves

title

optional title for plot, NULL for no title, 'auto' for auto generated title

plot

whether to plot results

plot_mort

whether to add mortality to plots

Value

ggplot object

Examples

1
2
df_res2 <- run_rot()
rot_plot_resistance(df_res2)

ian-hastings/rotations documentation built on Dec. 14, 2020, 11:42 p.m.