newEmptyPop {AlphaSimR} | R Documentation |
Creates an empty population
Description
Creates an empty Pop-class
object with user
defined ploidy and other parameters taken from simParam.
Usage
newEmptyPop(ploidy = 2L, simParam = NULL)
Arguments
ploidy |
the ploidy of the population |
simParam |
an object of |
Value
Returns an object of Pop-class
with
zero individuals
Examples
#Create founder haplotypes
founderPop = quickHaplo(nInd=2, nChr=1, segSites=10)
#Set simulation parameters
SP = SimParam$new(founderPop)
SP$addTraitA(10)
#Create empty population
pop = newEmptyPop(simParam=SP)
isPop(pop)
[Package AlphaSimR version 1.5.3 Index]