pullDroneGroupsFromDCA {SIMplyBee}R Documentation

Pulls drone groups from a Drone Congregation Area (DCA)

Description

Level 1 function that pulls drone groups from a Drone Congregation Area (DCA) to use them later in mating. Within the function drones are pulled (removed) from the DCA to reflect the fact that drones die after mating, so they can't be present in the DCA anymore. Be careful what you do with the DCA object outside function to avoid drone "copies".

Usage

pullDroneGroupsFromDCA(DCA, n, nDrones = NULL, simParamBee = NULL, ...)

Arguments

DCA

Pop-class, population of drones

n

integer, number of drone groups to be created

nDrones

numeric of function, number of drones that a virgin queen mates with; if NULL then SimParamBee$nFathers is used

simParamBee

SimParamBee, global simulation parameters

...

additional arguments passed to nDrones when this argument is a function

Value

list of Pop-class

Examples

founderGenomes <- quickHaplo(nInd = 8, nChr = 1, segSites = 100)
SP <- SimParamBee$new(founderGenomes)
basePop <- createVirginQueens(founderGenomes)

drones <- createDrones(x = basePop[1], nInd = 1000)
droneGroups <- pullDroneGroupsFromDCA(drones, n = 10, nDrones = nFathersPoisson)

# Create a Colony and a MultiColony class
colony <- createColony(x = basePop[2])
colony <- cross(colony, drones = droneGroups[[1]])
colony <- addDrones(colony, nInd = 100)

# Create colony DCA
DCA <- createDCA(colony)
pullDroneGroupsFromDCA(DCA, n = 4, nDrones = 5)
pullDroneGroupsFromDCA(DCA, n = 5, nDrones = nFathersPoisson)


[Package SIMplyBee version 0.3.0 Index]