Description Usage Arguments Value Author(s) Examples
Plot allele frequency evolution over time for each locus, grouping by population color. This shows the difference between selection types and population colors.
1 | loci.over.time(fr, pop.colors = pop.colors.default, generation = NULL, m = "Allele frequency evolution varies with selection type and population color", popsize.enc = NULL)
|
fr |
Data frame of simulated allele frequencies. |
pop.colors |
Colors to use to distinguish populations (blue, neutral, red) |
generation |
Generation to emphasize, or NULL for no emphasis. |
m |
Main title. |
popsize.enc |
Aesthetic to encode population size. lty or lwd work well. NULL means do not show population size. |
The ggplot2 plot.
Toby Dylan Hocking <toby.hocking@etu.upmc.fr>
1 2 3 4 5 6 | library(nicholsonppp)
sim <- sim.drift.selection(s=0.5,generations=100)
df <- sim2df(sim)
df.i <- interesting.loci(df)
stopifnot(nrow(df.i)/nrow(df)*sim$p$n.locus==6)
loci.over.time(df.i)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.