plot(randomPed(n = 7, seed = 12))
# Disallow mating between direct descendants
plot(randomPed(n = 7, seed = 12, maxDirectGap = 0))
# No restrictions on mating between direct descendants
plot(randomPed(n = 7, seed = 12, maxDirectGap = Inf))
# Allow selfing
y = randomPed(5, seed = 2, selfing = TRUE)
hasSelfing(y)
y
plot(y, arrows = TRUE)
Run the code above in your browser using DataLab