ERROR (Individual_Class::ExecuteMethod_zygosityOfMutations): zygosityOfMutations() requires that all mutations belong to the same species as the target individuals.
This error has invalidated the simulation; it cannot be run further. Once the script is fixed, you can recycle the simulation and try again.
which is weird because there is a single species in the simulation. Could it be related to multiple chromosomes (I haven't encountered this message in single-chromosome simulations yet, even with multiple subpopulations)?
initialize() {
setSeed(0);
defineConstant("M_RATE",10^-3);
defineConstant("M_VAR", 10^-3);
defineConstant("S_SD", sqrt(100.0) );
defineConstant("POP_SIZE", 1000 );
defineConstant("TRAIT_NAMES", c("ex1", "ex2", "ex3", "ex4") );
defineConstant("LLOCI", c(15, 60, 120, 300) );
for(L in LLOCI, m in seqAlong(LLOCI), trait in TRAIT_NAMES){
initializeChromosome(rdunif(1, 0, 1000), length=L, symbol=trait);
initializeMutationRate(M_RATE);
mut = initializeMutationType(m, 0.5, "n", 0.0, sqrt(M_VAR)); // QTLs
mut.mutationStackPolicy = 'l';
mut.convertToSubstitution = F;
g = initializeGenomicElementType(L, mut, 1.0);
initializeGenomicElement(g);
initializeRecombinationRate(0.5);
}
}
1 late() {
sim.addSubpop("p1", POP_SIZE);
sim.addSubpop("p2", POP_SIZE);
sim.addSubpop("p3", POP_SIZE);
sim.addSubpop("p4", POP_SIZE);
}
late() {
dos = p1.individuals.zygosityOfMutations(sim.mutationsOfType(m0));
}
30000 late(){sim.simulationFinished();}
The single-species WF model below returns the following error message:
which is weird because there is a single species in the simulation. Could it be related to multiple chromosomes (I haven't encountered this message in single-chromosome simulations yet, even with multiple subpopulations)?