to apply. The assumption is that the results will apply in general to both
clonal and sexual organisms. A comparison of Scenario 6 in this chapter
with Scenario 5 of the next chapter, in which the same scenario is exam-
ined using a quantitative genetic pers pective scenario, suggests t hat this
assumption may, in some instances, be erroneous. Given this, I believe that
it is better to regard the analysis not as a biological scenario but simply as
a mathematical means of judging potential evolutionary history in the
sense of movement to a single ESS, maintenance of polymorphisms or
the existence of multiple equilibr ia. In the two examples presented in
the subsequent scenarios I assume that a new type is introduced into the
population at each generation: should this be judged too liberal, it is easy
to alter the coding to make the introduction of a new type a probabilistic
event (e.g., the type of “mutation” could be depend on the frequency of
types already present in the population). Based on the assumption that a
new type appears at each generation and is a random draw from all the
possible types (this could also be changed such that the frequency distribu-
tion is, say, normal r ather than uniform), coding is
for (Igen in 1:Maxgen)
{
N.total <- sum(Data[,2]) # Total population size
Data[,2] <- apply(Data,1,DD.FUNCTION, N.total) # New cohort
# Keep track of population size, mean trait value and SD of trait value
Stats[Igen,2] <- sum(Data[,1]*Data[,2])/sum(Data[,2]) # Mean
S <- sum(Data[,2]) # Popn size
Stats[Igen,1] <- S # Popn size
SX1 <- sum(Data[,1]^2*Data[,2])
SX2 <- (sum(Data[,1]*Data[,2]))^2/S
Stats[Igen,3] <- sqrt((SX1-SX2)/(S-1)) # SD of trait
# Introduce a mutant by picking a random integer between 1 and 50
Mutant <- ceiling(runif(1, min¼0, max¼50))
Data[Mutant,2] <- Data[Mutant,2]þ1 # Add mutant to class
} # End of Igen loop
In the above coding the program keeps track of the total population size, Stats
[Igen,1], the mean trait value, Stats[Igen,2], and its standard deviation,
Stats[Igen,3]. If there is a unique equilibrium the mean value should asymp-
tote to this value and the standard deviation should equilibrate at a value deter-
mined by the difference between adjacent bins of the trait value (i.e., Data[,1]).
If there are multiple equilibria the mean should fluctuate and the standard devia-
tion should not reach a small limiting value. A plot of trait value class on popula-
tion size (called a frequency polygon) is useful to provide a visual indication of the
spread of the trait values.
INVASIBILITY ANALYSIS 183