library(knitr)
#https://stackoverflow.com/a/36234023/1718356 for fig.pos = 'h'

opts_chunk$set(fig.height=3, fig.width=7, fig.pos = 'h', echo=FALSE, warning=FALSE, message=FALSE)

# #these options make the pdf fail but do create the tiffs
opts_chunk$set(fig.height=3, fig.width=7, fig.pos = 'h', echo=FALSE, warning=FALSE, message=FALSE,
               dev="tiff",
               dev.args=list(compression="lzw"),
               dpi=300,
               cache=FALSE,
               fig.path='figs/')
  library(rotations)
  library(ggplot2)

In sequential use an insecticide is changed when it reaches a resistance threshold, in contrast in a rotation an insecticide is changed before it reaches a resistant threshold.

If there are no costs of resistance or migration from untreated areas then rotations and sequences are likely to result in very similar effect on resistance frequencies as seen in the following plots.

These plots assume that an insecticide is changed when it reaches the resistance frequency threshold even if the rotation interval has yet to be reached. Without this assumption then rotations always take a little longer time than sequences but at the expense of reaching slightly higher resistance frequencies.

The plots here are for 2 insecticides to keep things simple however the model can be run for any number of insecticides. Effectiveness of insecticides at killing SS is set to 0.8 unless indicated.

dfrot0 <- run_rot(n_insecticides=2, rot_interval=0, expo_hi=0.5, eff=0.8, cost=0, coverage=1)
dfrot15 <- run_rot(n_insecticides=2, max_gen = 200, rot_interval=10, expo_hi=0.5, eff=0.8, cost=0, coverage=1)
#eval=FALSE
dfr <- run_rot(n_insecticides=2, max_gen = 200, rot_interval=30, expo_hi=0.5, eff=0.8, cost=0, coverage=1)

\newpage

costs of resistance

If there are costs of resistance then we would expect resistance frequencies to decline when an insecticide is not in use. However this may not make much difference between the effect of a sequence and a rotation. In a sequence the resistance frequency builds up once and then gets a long period to decline when not in use. In a rotation resistance frequency increases as a series of small steps with short declines in between (see following plots). The time it takes for both insecticides to reach the resistance threshold of 50% is still very similar for a sequence and a rotation.

(This is assuming that costs don't change according to the frequency of the resistance allele - there is some evidence to suggest that costs may decline when a resistance allele has been at a high frequency for a long time (mentioned in GPIRM), if this is the case then it could indeed provide an advantage for rotations over sequences).

dfseq <- run_rot(n_insecticides=2, max_gen = 200, rot_interval=0, expo_hi=0.5, eff=0.8, cost=0.01, coverage=1)
dfrot <- run_rot(n_insecticides=2, max_gen = 200, rot_interval=10, expo_hi=0.5, eff=0.8, cost=0.01, coverage=1)

#to compare 2 previous scenarios
#rot_plot_resistance(dfrot, df_resanother=dfseq, plot_refuge=FALSE)

\newpage

costs of resistance

Costs increased to 5%.

dfseq <- run_rot(n_insecticides=2, max_gen = 200, rot_interval=0, expo_hi=0.5, eff=0.8, cost=0.05, coverage=1)
dfrot <- run_rot(n_insecticides=2, max_gen = 200, rot_interval=10, expo_hi=0.5, eff=0.8, cost=0.05, coverage=1)

#to compare 2 previous scenarios
#rot_plot_resistance(dfrot, df_resanother=dfseq, plot_refuge=FALSE)

\newpage

immigration from untreated areas

Even without costs of resistance we might expect resistance frequencies to decline when an insecticide is not in use due to immigration from nearby areas that were not treated originally. This is shown in the following two plots where a neighbouring untreated area ('refuge') and exchange of migrants is represented. In this example the treated and untreated areas are set to the same size and migration at 1%. The time it takes for both insecticides to reach the resistance threshold of 50% is still very similar for a sequence and a rotation.

dfr <- run_rot(n_insecticides=2, max_gen = 130, rot_interval=0, expo_hi=0.5, eff=0.8, cost=0, coverage=0.5, migration = 0.02)
dfr <- run_rot(n_insecticides=2, max_gen = 130, rot_interval=10, expo_hi=0.5, eff=0.8, cost=0, coverage=0.5, migration = 0.02)

\newpage

more insecticides

dfr <- run_rot(n_insecticides=4, max_gen = 130, rot_interval=0, expo_hi=0.5, eff=0.8, cost=0, coverage=0.1, migration = 0.05)
dfr <- run_rot(n_insecticides=4, max_gen = 130, rot_interval=10, expo_hi=0.5, eff=0.8, cost=0, coverage=0.1, migration = 0.05)

\newpage

costs and immigration

Including both costs of resistance and immigration from an untreated area, still results in little difference between a sequence and rotation in terms of time-to-resistance to both insecticides.

dfr <- run_rot(n_insecticides=2, max_gen = 200, rot_interval=0, expo_hi=0.5, eff=0.8, cost=0.05, coverage=0.5, migration = 0.01)
dfr <- run_rot(n_insecticides=2, max_gen = 200, rot_interval=10, expo_hi=0.5, eff=0.8, cost=0.05, coverage=0.5, migration = 0.01)

knitr::knit_exit()

plots after this don't show much interesting

\newpage

dominance

In all the preceeding plots dominance of resistance and dominance of cost were set to 0.5. Here we check whether changing the dominance of cost between 0 and 1 has an effect on rotations. It does not appear to change time to the 50% resistance threshold, on the following page we try increasing the threshold.

dfr <- run_rot(n_insecticides=2, max_gen = 200, rot_interval=10, expo_hi=0.5, eff=0.8, cost=0.005, coverage=1, migration = 0, dom_cos = 0)
dfr <- run_rot(n_insecticides=2, max_gen = 200, rot_interval=10, expo_hi=0.5, eff=0.8, cost=0.005, coverage=1, migration = 0, dom_cos = 1)

\newpage

dominance of cost effects with increased resistance threshold (90%)

Still little difference between sequence and rotation.

dfr <- run_rot(n_insecticides=2, max_gen = 200, rot_interval=0, expo_hi=0.5, eff=0.8, cost=0.005, coverage=1, migration = 0, dom_cos = 0, threshold = 0.9, start_freqs = 0.001)
dfr <- run_rot(n_insecticides=2, max_gen = 200, rot_interval=10, expo_hi=0.5, eff=0.8, cost=0.005, coverage=1, migration = 0, dom_cos = 0, threshold = 0.9, start_freqs = 0.001)
dfr <- run_rot(n_insecticides=2, max_gen = 200, rot_interval=0, expo_hi=0.5, eff=0.8, cost=0.005, coverage=1, migration = 0, dom_cos = 1, threshold = 0.9, start_freqs = 0.001)
dfr <- run_rot(n_insecticides=2, max_gen = 200, rot_interval=10, expo_hi=0.5, eff=0.8, cost=0.005, coverage=1, migration = 0, dom_cos = 1, threshold = 0.9, start_freqs = 0.001)


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